MCPcopy Index your code
hub / github.com/codeaashu/claude-code / handleOAuth401Error

Function handleOAuth401Error

src/utils/auth.ts:1360–1371  ·  view source on GitHub ↗
(
  failedAccessToken: string,
)

Source from the content-addressed store, hash-verified

1358 * @returns true if we now have a valid token, false otherwise
1359 */
1360export function handleOAuth401Error(
1361 failedAccessToken: string,
1362): Promise<boolean> {
1363 const pending = pending401Handlers.get(failedAccessToken)
1364 if (pending) return pending
1365
1366 const promise = handleOAuth401ErrorImpl(failedAccessToken).finally(() => {
1367 pending401Handlers.delete(failedAccessToken)
1368 })
1369 pending401Handlers.set(failedAccessToken, promise)
1370 return promise
1371}
1372
1373async function handleOAuth401ErrorImpl(
1374 failedAccessToken: string,

Callers 4

withOAuth401RetryFunction · 0.85
doFetchFunction · 0.85
createClaudeAiProxyFetchFunction · 0.85
withRetryFunction · 0.85

Calls 4

handleOAuth401ErrorImplFunction · 0.85
getMethod · 0.65
deleteMethod · 0.65
setMethod · 0.45

Tested by

no test coverage detected