From 71452a293f7e9876786bb1f6b8322554ee8293a5 Mon Sep 17 00:00:00 2001 From: Philipp Kunz Date: Thu, 20 Jan 2022 18:38:17 +0100 Subject: [PATCH] fix(core): update --- ts/smartsocket.classes.smartsocketclient.ts | 13 +++---------- 1 file changed, 3 insertions(+), 10 deletions(-) diff --git a/ts/smartsocket.classes.smartsocketclient.ts b/ts/smartsocket.classes.smartsocketclient.ts index 62e687c..f139459 100644 --- a/ts/smartsocket.classes.smartsocketclient.ts +++ b/ts/smartsocket.classes.smartsocketclient.ts @@ -212,8 +212,10 @@ export class SmartsocketClient { if (this.autoReconnect && useAutoReconnectSetting && this.eventStatus !== 'connecting') { this.updateStatus('connecting'); - await this.tryDebouncedReconnect(); + console.log('debounced reconnect!'); + await plugins.smartdelay.delayForRandom(10000, 20000); this.disconnectRunning = false; + await this.connect(); } else { this.disconnectRunning = false; } @@ -227,15 +229,6 @@ export class SmartsocketClient { await this.disconnect(); } - /** - * try a reconnection - */ - public async tryDebouncedReconnect() { - console.log('debounced reconnect!'); - await plugins.smartdelay.delayForRandom(10000, 20000); - await this.connect(); - } - /** * dispatches a server call * @param functionNameArg