MCPcopy
hub / github.com/buildbot/buildbot / endpointPath

Function endpointPath

www/data-module/src/data/DataUtils.ts:47–56  ·  view source on GitHub ↗
(arg: string | string[])

Source from the content-addressed store, hash-verified

45}
46
47export function endpointPath(arg: string | string[]) {
48 // if the argument count is even, the last argument is an id
49 let a = copyOrSplit(arg);
50 a = a.filter(e => e !== '*');
51 // is it even?
52 if ((a.length % 2) === 0) {
53 a.pop();
54 }
55 return a.join('/');
56}
57
58export function splitOptions(args: any[]) {
59 // keep defined arguments only

Callers 3

openMethod · 0.90
openMethod · 0.90
DataUtils.test.tsFile · 0.90

Calls 4

copyOrSplitFunction · 0.85
popMethod · 0.80
filterMethod · 0.45
joinMethod · 0.45

Tested by

no test coverage detected