diff --git a/apps/widalarmeta/ChangeLog b/apps/widalarmeta/ChangeLog index 8bdf1156f..1012ee386 100644 --- a/apps/widalarmeta/ChangeLog +++ b/apps/widalarmeta/ChangeLog @@ -4,3 +4,4 @@ Add option to show seconds 0.03: Fix Bell not appearing on alarms > 24h and redrawing interval Update to match the default alarm widget, and not show itself when an alarm is hidden. +0.04: Fix check for active alarm diff --git a/apps/widalarmeta/metadata.json b/apps/widalarmeta/metadata.json index 89e35c090..aad3c4321 100644 --- a/apps/widalarmeta/metadata.json +++ b/apps/widalarmeta/metadata.json @@ -2,7 +2,7 @@ "id": "widalarmeta", "name": "Alarm & Timer ETA", "shortName": "Alarm ETA", - "version": "0.03", + "version": "0.04", "description": "A widget that displays the time to the next Alarm or Timer in hours and minutes, maximum 24h (configurable).", "icon": "widget.png", "type": "widget", diff --git a/apps/widalarmeta/widget.js b/apps/widalarmeta/widget.js index 8615aa1d2..3ad2e6ad2 100644 --- a/apps/widalarmeta/widget.js +++ b/apps/widalarmeta/widget.js @@ -9,10 +9,10 @@ function draw() { const times = alarms - .map(alarm => { + .map(alarm => alarm.hidden !== true && require("sched").getTimeToAlarm(alarm) - }) + ) .filter(a => a !== undefined); const next = times.length > 0 ? Math.min.apply(null, times) : 0; let calcWidth = 0;