MCPcopy Create free account
hub / github.com/UsefulSoftwareCo/executor / toError

Function toError

packages/kernel/runtime-quickjs/src/index.ts:67–68  ·  view source on GitHub ↗
(cause: unknown)

Source from the content-addressed store, hash-verified

65const EXECUTION_FILENAME = "executor-quickjs-runtime.js";
66
67const toError = (cause: unknown): Error =>
68 cause instanceof Error ? cause : new Error(String(cause));
69
70// Defect surfaced to the sandbox when a tool dispatch reaches the
71// reject path. Two sources reach here:

Callers 3

toErrorMessageFunction · 0.70
serializeJsonFunction · 0.70
drainJobsFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected