From 086771ee669c6768e805bb4e6315abab8ef6edc1 Mon Sep 17 00:00:00 2001 From: Ralf Becker Date: Tue, 27 Oct 2020 14:19:25 +0100 Subject: [PATCH] try to fix race-condition in reconnecting a "lost" websocket connection --- api/js/jsapi/egw_json.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/api/js/jsapi/egw_json.js b/api/js/jsapi/egw_json.js index b0d12c9d3c..c9abfd9c45 100644 --- a/api/js/jsapi/egw_json.js +++ b/api/js/jsapi/egw_json.js @@ -122,7 +122,7 @@ egw.extend('json', egw.MODULE_WND_LOCAL, function(_app, _wnd) { this.websocket = null; this.openWebSocket(url, tokens, account_id, error, reconnect_time); - } + }.bind(this); this.websocket.close(); // closing it now, before reopening it, to not end up with multiple connections }.bind(this), max_ping_response_time); }.bind(this);