🐛 fix identify schema

This commit is contained in:
Flam3rboy
2021-05-07 22:52:40 +02:00
parent 22e8e83ab9
commit 372bfd9beb
2 changed files with 4 additions and 1 deletions
+2 -1
View File
@@ -1,3 +1,4 @@
import { CLOSECODES } from "./Constants";
import WebSocket from "./WebSocket";
// TODO: make heartbeat timeout configurable
@@ -5,6 +6,6 @@ export function setHeartbeat(socket: WebSocket) {
if (socket.heartbeatTimeout) clearTimeout(socket.heartbeatTimeout);
socket.heartbeatTimeout = setTimeout(() => {
return socket.close(4009);
return socket.close(CLOSECODES.Session_timed_out);
}, 1000 * 45);
}