From 352ba02adde0fe43a0531b08cd3c5332ea12b279 Mon Sep 17 00:00:00 2001 From: DEV2DEV_DE Date: Wed, 29 Nov 2023 20:31:22 +0100 Subject: [PATCH] Improve rampdown onUnload() --- main.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/main.js b/main.js index a5e0fca..e970b52 100644 --- a/main.js +++ b/main.js @@ -357,7 +357,7 @@ class Jablotron extends utils.Adapter { async onUnload(callback) { try { await this.setState('info.connection', { val: false, ack: true }); - if (this.timeout) this.clearTimeout(this.timeout); + if (this.timeout) await this.clearTimeout(this.timeout); callback(); } catch (e) { callback();