diff --git a/meshuser.js b/meshuser.js index c651d4e7..58a4725a 100644 --- a/meshuser.js +++ b/meshuser.js @@ -5728,7 +5728,7 @@ module.exports.CreateMeshUser = function (parent, db, ws, req, args, domain, use function serverCommandClose(command) { // Close the web socket session - try { delete obj.req.session.ws; } catch (e) { } + try { if (obj.req.session.ws == ws) delete obj.req.session.ws; } catch (e) { } try { ws.close(); } catch (e) { } }