fix frontend reload again

This commit is contained in:
zadam
2019-06-26 20:49:17 +02:00
parent 20d3d61cec
commit 7c77ae758b
4 changed files with 13 additions and 10 deletions
+7 -4
View File
@@ -88,10 +88,13 @@ setTimeout(() => {
console.log("Lost connection to server");
}
ws.send(JSON.stringify({
type: 'ping',
lastSyncId: lastSyncId
}));
try {
ws.send(JSON.stringify({
type: 'ping',
lastSyncId: lastSyncId
}));
}
catch (e) {} // if the connection is closed then this produces a lot of messages
}, 1000);
}, 0);