MCPcopy Create free account
hub / github.com/FlashpointProject/launcher / close

Method close

src/back/SocketServer.ts:101–112  ·  view source on GitHub ↗

Close the server.

()

Source from the content-addressed store, hash-verified

99 }
100 /** Close the server. */
101 public close(): Promise<void> {
102 return new Promise((resolve, reject) => {
103 if (this.server) {
104 this.server.close(error => {
105 if (error) { reject(error); }
106 else { resolve(); }
107 });
108 } else {
109 reject(new Error('Failed to close server. No server is open.'));
110 }
111 });
112 }
113
114 // ...
115

Callers

nothing calls this directly

Calls 1

closeMethod · 0.65

Tested by

no test coverage detected