MCPcopy Create free account
hub / github.com/MoonshotAI/kimi-code / getErrorCode

Function getErrorCode

packages/agent-core/src/mcp/config-loader.ts:153–156  ·  view source on GitHub ↗
(error: unknown)

Source from the content-addressed store, hash-verified

151}
152
153function getErrorCode(error: unknown): unknown {
154 if (typeof error !== 'object' || error === null || !('code' in error)) return undefined;
155 return (error as { code: unknown }).code;
156}
157
158function describeError(error: unknown): string {
159 return error instanceof Error ? error.message : String(error);

Callers 2

isFileNotFoundFunction · 0.70
isPathMissingFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected