MCPcopy Index your code
hub / github.com/anomalyco/opencode / check

Function check

packages/opencode/test/server/httpapi-exercise/assertions.ts:46–48  ·  view source on GitHub ↗
(value: boolean, message: string)

Source from the content-addressed store, hash-verified

44}
45
46export function check(value: boolean, message: string): asserts value {
47 if (!value) throw new Error(message)
48}
49
50export function message(error: unknown) {
51 if (error instanceof Error) return error.message

Callers 1

index.tsFile · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected