From 999d40256496dfe7beff3a8f422fa31f3fc3df92 Mon Sep 17 00:00:00 2001 From: stonedDiscord Date: Fri, 26 Jul 2019 13:15:11 +0200 Subject: the connection was already dead --- webAO/client.js | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) (limited to 'webAO') diff --git a/webAO/client.js b/webAO/client.js index 9b53432..57b0d0c 100644 --- a/webAO/client.js +++ b/webAO/client.js @@ -431,11 +431,7 @@ class Client extends EventEmitter { } cleanup() { - try { - this.serv.close(1001); - } finally { - clearInterval(this.checkUpdater); - } + clearInterval(this.checkUpdater); } /** @@ -1620,7 +1616,7 @@ async function changeBackground(position) { * Triggered when the reconnect button is pushed. */ export function ReconnectButton() { - //client.cleanup(); + client.cleanup(); client = new Client(serverIP); console.log(client); if (client) { -- cgit