fix(ws/shard): use WebSocket#close() instead of WebSocket#send() to close connection (#518)

* fix(ws/shard): use WebSocket#close() instead of WebSocket#send() to close connection

* Oops forgot the return statement
This commit is contained in:
ayntee
2021-02-13 12:14:23 +04:00
committed by GitHub
parent ce99dc3e0a
commit 043fe5c308
+2 -1
View File
@@ -228,7 +228,8 @@ async function heartbeat(
}, },
}, },
); );
return shard.ws.send(JSON.stringify({ op: 4009 }));
return shard.ws.close(4009, "Session timed out");
} }
} }