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

Function isConnectionError

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

Source from the content-addressed store, hash-verified

1588])
1589
1590export function isConnectionError(err: unknown): boolean {
1591 if (
1592 err &&
1593 typeof err === 'object' &&
1594 'code' in err &&
1595 typeof err.code === 'string' &&
1596 CONNECTION_ERROR_CODES.has(err.code)
1597 ) {
1598 return true
1599 }
1600 return false
1601}
1602
1603/** Detect HTTP 5xx errors from axios (code: 'ERR_BAD_RESPONSE'). */
1604export function isServerError(err: unknown): boolean {

Callers 1

runBridgeLoopFunction · 0.85

Calls 1

hasMethod · 0.45

Tested by

no test coverage detected