MCPcopy Create free account
hub / github.com/tiann/hapi / getString

Function getString

cli/src/opencode/opencodeLocalLauncher.ts:38–43  ·  view source on GitHub ↗
(value: unknown)

Source from the content-addressed store, hash-verified

36type PermissionDecision = PermissionCompletion['decision'];
37
38function getString(value: unknown): string | null {
39 if (typeof value === 'string' && value.trim().length > 0) {
40 return value.trim();
41 }
42 return null;
43}
44
45function parseMaybeJson(value: unknown): unknown {
46 if (typeof value !== 'string') {

Callers 4

extractSessionIdFunction · 0.70
parseToolCallFunction · 0.70
parseToolResultFunction · 0.70
handleHookEventFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected