From cc0f223c33ac29d2055d4f0f6a51cd26e71897ce Mon Sep 17 00:00:00 2001 From: Ryjek Date: Thu, 11 Jun 2026 14:05:10 +0200 Subject: [PATCH] small fix --- app.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/app.js b/app.js index 050eddc..fbf5314 100644 --- a/app.js +++ b/app.js @@ -70,7 +70,9 @@ io.on('connection', function(socket) { socket.on('disconnect', () => { const room = socket.handshake.query.id; console.log('user ' + socket.id + ' disconnected'); - queue[room]=[]; + if (typeof queue[room] === "undefined") { + queue[room]=[]; + } console.log('create queue: ' + room); }); });