MCPcopy Create free account
hub / github.com/colbymchenry/codegraph / close

Method close

src/ui-server/api/events.ts:255–267  ·  view source on GitHub ↗

Stop watching and end every open stream. Idempotent.

()

Source from the content-addressed store, hash-verified

253
254 /** Stop watching and end every open stream. Idempotent. */
255 close(): void {
256 this.closed = true;
257 this.stopWatching();
258 for (const client of [...this.clients]) {
259 clearInterval(client.heartbeat);
260 this.clients.delete(client);
261 try {
262 client.res.end();
263 } catch {
264 /* the socket is already gone */
265 }
266 }
267 }
268
269 /* ------------------------------------------------------------ plumbing -- */
270

Callers 1

createGraphApiFunction · 0.95

Calls 2

stopWatchingMethod · 0.95
deleteMethod · 0.65

Tested by

no test coverage detected