MCPcopy
hub / github.com/claude-code-best/claude-code / writeSocketErrorAndDestroy

Function writeSocketErrorAndDestroy

src/utils/udsMessaging.ts:367–373  ·  view source on GitHub ↗
(socket: Socket, data: string)

Source from the content-addressed store, hash-verified

365}
366
367function writeSocketErrorAndDestroy(socket: Socket, data: string): void {
368 writeSocketMessageAndDestroy(socket, {
369 type: 'error',
370 data,
371 ts: new Date().toISOString(),
372 })
373}
374
375function unrefTimer(timer: ReturnType<typeof setTimeout>): void {
376 const maybeUnref = (timer as { unref?: () => void }).unref

Callers 1

closeWithErrorFunction · 0.85

Calls 1

Tested by

no test coverage detected