From 926f5d122479ce9239fbd285693b7334ab2c66de Mon Sep 17 00:00:00 2001 From: xdrm-brackets Date: Wed, 6 Dec 2017 18:23:48 +0100 Subject: [PATCH] upd: view.main (removed websocket closing protocol (PING/PONG will destroy it automatically)) --- view/main.js | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/view/main.js b/view/main.js index 6484cb3..5969353 100755 --- a/view/main.js +++ b/view/main.js @@ -122,13 +122,4 @@ window.wsc_chat = wsc.channel('chat').listen(function(msg, err){ if( router.app.$route.path != 'inbox' ) gstore.data.notif[1].count += msg.msg.length -}).send({name: _SERVER.session.name}); - - - -/* (4) Clean sockets before page quit ----------------------------------------------------------*/ -window.onbeforeunload = function() { - wsc_chat.send('{"close": true}'); - wsc_connect.send('{"close": true}'); -}; \ No newline at end of file +}).send({name: _SERVER.session.name}); \ No newline at end of file