diff options
author | 2023-05-11 15:10:06 -0700 | |
---|---|---|
committer | 2023-05-11 15:10:06 -0700 | |
commit | 7141e19a101d3afc22226bbde2a7630f939a7ee1 (patch) | |
tree | 7bd14a7e34efbfecf08b3d2dfd569505c72e45bb /src | |
parent | 5c08200b1845fad5a97c864a63c3f03424c15fab (diff) | |
download | bun-7141e19a101d3afc22226bbde2a7630f939a7ee1.tar.gz bun-7141e19a101d3afc22226bbde2a7630f939a7ee1.tar.zst bun-7141e19a101d3afc22226bbde2a7630f939a7ee1.zip |
fixup
Diffstat (limited to 'src')
-rw-r--r-- | src/bun.js/http.exports.js | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/bun.js/http.exports.js b/src/bun.js/http.exports.js index 539f7f8f8..8fe1265c5 100644 --- a/src/bun.js/http.exports.js +++ b/src/bun.js/http.exports.js @@ -238,7 +238,8 @@ export class Server extends EventEmitter { close(optionalCallback) { const server = this.#server; if (!server) { - if (typeof optionalCallback === "function") process.nextTick(new Error("Server is not running")); + if (typeof optionalCallback === "function") + process.nextTick(optionalCallback, new Error("Server is not running")); return; } this.#server = undefined; |