MCPcopy Create free account
hub / github.com/codeaashu/claude-code / isServerError

Function isServerError

src/bridge/bridgeMain.ts:1604–1612  ·  view source on GitHub ↗
(err: unknown)

Source from the content-addressed store, hash-verified

1602
1603/** Detect HTTP 5xx errors from axios (code: 'ERR_BAD_RESPONSE'). */
1604export function isServerError(err: unknown): boolean {
1605 return (
1606 !!err &&
1607 typeof err === 'object' &&
1608 'code' in err &&
1609 typeof err.code === 'string' &&
1610 err.code === 'ERR_BAD_RESPONSE'
1611 )
1612}
1613
1614/** Add ±25% jitter to a delay value. */
1615function addJitter(ms: number): number {

Callers 1

runBridgeLoopFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected