MCPcopy
hub / github.com/di-sukharev/opencommit / b3

Function b3

out/cli.cjs:65203–65212  ·  view source on GitHub ↗
(t2, e3, r3, n2)

Source from the content-addressed store, hash-verified

65201 const f4 = l3.slice(-3) === "...";
65202 f4 && (n2 = a4, l3 = l3.slice(0, -3));
65203 const p4 = l3.match(V3);
65204 if (p4) throw new Error(`Invalid parameter: ${d3(a4)}. Invalid character found ${d3(p4[0])}`);
65205 e3.push({ name: l3, required: o3, spread: f4 });
65206 }
65207 return e3;
65208}
65209function b3(t2, e3, r3, n2) {
65210 for (let a4 = 0; a4 < e3.length; a4 += 1) {
65211 const { name: i3, required: s2, spread: o3 } = e3[a4], l3 = S2(i3);
65212 if (l3 in t2) throw new Error(`Invalid parameter: ${d3(i3)} is used more than once.`);
65213 const f4 = o3 ? r3.slice(a4) : r3[a4];
65214 if (o3 && (a4 = e3.length), s2 && (!f4 || o3 && f4.length === 0)) return console.error(`Error: Missing required parameter ${d3(i3)}
65215`), n2(), process.exit(1);

Callers 1

x2Function · 0.85

Calls 4

S2Function · 0.85
n2Function · 0.85
sliceMethod · 0.45
errorMethod · 0.45

Tested by

no test coverage detected