diff --git a/src/ws/index.ts b/src/ws/index.ts index d36b635..7a3e5cc 100644 --- a/src/ws/index.ts +++ b/src/ws/index.ts @@ -54,6 +54,11 @@ const onclose = () => { console.log("ws disconnected. reconnecting"); ws = new WebSocket("ws://localhost/ws"); ws.onopen = () => { + messages = []; + users = []; + queue = new Array(6).fill(null); + dirty = true; + console.log("opened websocket!"); if (!token) { ws.send(JSON.stringify({