From aa05c9c8d404dfffae9f11f9f3ef565deb37c822 Mon Sep 17 00:00:00 2001 From: Anthony Merlo Date: Fri, 21 Aug 2026 00:10:45 +0100 Subject: [PATCH] fix: await Notification.schedule() so notification fires before script exits --- scripts/health-sync.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/health-sync.js b/scripts/health-sync.js index 577d4b8..f72423a 100644 --- a/scripts/health-sync.js +++ b/scripts/health-sync.js @@ -49,11 +49,11 @@ function todayDate() { return new Date().toISOString().slice(0, 10); } -function notify(body) { +async function notify(body) { const n = new Notification(); n.title = "Health Sync"; n.body = body; - n.schedule(); + await n.schedule(); } // --- Read all health metrics ---