MCPcopy Create free account
hub / github.com/AnukarOP/claude-code-leaked / getJsonInput

Function getJsonInput

source code/utils/hooks.ts:2130–2142  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

2128 | { ok: false; error: unknown }
2129 | undefined
2130 function getJsonInput() {
2131 if (jsonInputResult !== undefined) {
2132 return jsonInputResult
2133 }
2134 try {
2135 return (jsonInputResult = { ok: true, value: jsonStringify(hookInput) })
2136 } catch (error) {
2137 logError(
2138 Error(`Failed to stringify hook ${hookName} input`, { cause: error }),
2139 )
2140 return (jsonInputResult = { ok: false, error })
2141 }
2142 }
2143
2144 // Run all hooks in parallel with individual timeouts
2145 const hookPromises = matchingHooks.map(async function* (

Callers 1

executeHooksFunction · 0.85

Calls 2

jsonStringifyFunction · 0.85
logErrorFunction · 0.70

Tested by

no test coverage detected