MCPcopy
hub / github.com/openclaw/clawsweeper / stringArg

Function stringArg

src/repair/commit-finding-intake.ts:673–676  ·  view source on GitHub ↗
(name: string, fallback: JsonValue)

Source from the content-addressed store, hash-verified

671}
672
673function stringArg(name: string, fallback: JsonValue) {
674 const value = args[name];
675 return typeof value === "string" && value.length ? value : fallback;
676}
677
678function assertSha(value: JsonValue) {
679 if (!/^[0-9a-f]{40}$/i.test(value)) die(`invalid commit sha: ${value}`);

Callers 2

prepareFunction · 0.70
finalizeFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected