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

Function onClose

packages/opencode/src/plugin/openai/ws.ts:119–122  ·  view source on GitHub ↗
(code: number, reason: Buffer)

Source from the content-addressed store, hash-verified

117 }
118
119 function onClose(code: number, reason: Buffer) {
120 cleanup()
121 reject(new Error(closeMessage("WebSocket closed before open", code, reason)))
122 }
123
124 function onAbort() {
125 cleanup()

Callers

nothing calls this directly

Calls 4

closeMessageFunction · 0.85
cleanupFunction · 0.70
invalidateFunction · 0.70
rejectFunction · 0.50

Tested by

no test coverage detected