Fix retryOnDisconnect and timer not clean up after reconnected

This commit is contained in:
Wu Cheng-Han 2016-07-02 16:13:34 +08:00
parent 858b30c20c
commit 1df5b4ce49
1 changed files with 2 additions and 2 deletions

View File

@ -2105,11 +2105,11 @@ socket.on('reconnect', function (data) {
emitUserStatus(true);
cursorActivity();
socket.emit('online users');
});
socket.on('connect', function (data) {
clearInterval(retryTimer);
retryTimer = null;
retryOnDisconnect = false;
});
socket.on('connect', function (data) {
personalInfo['id'] = socket.id;
showStatus(statusType.connected);
socket.emit('version');