Disable notifications on new 'reconnect' event for laptop resume

This commit is contained in:
Scott Nonnenberg 2018-07-03 14:56:30 -07:00
parent e83e10a7d1
commit a40a39314a
2 changed files with 14 additions and 0 deletions

View file

@ -39,6 +39,12 @@ MessageReceiver.prototype.extend({
return;
}
this.count = 0;
if (this.hasConnected) {
const ev = new Event('reconnect');
this.dispatchEvent(ev);
}
this.hasConnected = true;
if (this.socket && this.socket.readyState !== WebSocket.CLOSED) {