From 528716322a0656e9530d657b7960912bb8a92b51 Mon Sep 17 00:00:00 2001 From: storm64 Date: Thu, 17 Nov 2022 09:26:51 +0100 Subject: [PATCH] [sleeplog] Correct fn call for trigger --- apps/sleeplog/boot.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/sleeplog/boot.js b/apps/sleeplog/boot.js index 75383c7df..17e5fe70a 100644 --- a/apps/sleeplog/boot.js +++ b/apps/sleeplog/boot.js @@ -270,7 +270,7 @@ if (sleeplog.conf.enabled) { if (typeof entry.fn === "function" && (changed || !entry.onChange) && (entry.from || 0) <= time && (entry.to || 24 * 60 * 60 * 1000) >= time) // and call afterwards with status data - setTimeout(fn, 100, { + setTimeout(entry.fn, 100, { timestamp: new Date(data.timestamp), status: data.status === this.status ? undefined : data.status, consecutive: data.consecutive === this.consecutive ? undefined : data.consecutive,