diff --git a/umap/static/umap/js/modules/sync/engine.js b/umap/static/umap/js/modules/sync/engine.js index c8451392..44c41017 100644 --- a/umap/static/umap/js/modules/sync/engine.js +++ b/umap/static/umap/js/modules/sync/engine.js @@ -72,9 +72,11 @@ export class SyncEngine { }) const [response, _, error] = await this._umap.server.get(websocketTokenURI) - if (!error) { - this.start(response.token) + if (error) { + this.reconnect() + return } + this.start(response.token) } start(authToken) {