mirror of
https://github.com/ragestudio/linebridge.git
synced 2025-06-09 02:24:17 +00:00
fix exit handler
This commit is contained in:
parent
604edd49ae
commit
daa0110c7e
@ -123,7 +123,6 @@ class Server {
|
||||
// handle exit events
|
||||
process.on("SIGTERM", this.cleanupProcess)
|
||||
process.on("SIGINT", this.cleanupProcess)
|
||||
process.on("exit", this.cleanupProcess)
|
||||
}
|
||||
|
||||
initializeHeaders = () => {
|
||||
@ -271,10 +270,12 @@ class Server {
|
||||
}
|
||||
|
||||
cleanupProcess = () => {
|
||||
console.log("🔴 Stopping server...")
|
||||
console.log("🛑 Stopping server...")
|
||||
|
||||
this.httpInterface.close()
|
||||
this.wsInterface.io.close()
|
||||
|
||||
process.exit(1)
|
||||
}
|
||||
|
||||
// handlers
|
||||
|
Loading…
x
Reference in New Issue
Block a user