From cb4da60c86f2a568376dbf2cc4c58095ebf60717 Mon Sep 17 00:00:00 2001 From: Bas Buijsen <72604903+deBasMan21@users.noreply.github.com> Date: Mon, 31 Aug 2026 19:54:46 +0200 Subject: [PATCH] Update calendar.js --- defaultmodules/calendar/calendar.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/defaultmodules/calendar/calendar.js b/defaultmodules/calendar/calendar.js index e70cbb852d..a42c54f388 100644 --- a/defaultmodules/calendar/calendar.js +++ b/defaultmodules/calendar/calendar.js @@ -588,9 +588,9 @@ Module.register("calendar", { if (eventsByDate[dateStr] && eventsByDate[dateStr].length > 0) { // If there are any events today then get all those events and select the currently active events and the events that are starting later in the day. newEvents.push(...eventsByDate[dateStr].filter((ev) => this.timestampToMoment(ev.endDate).isAfter(moment()))); - // Since we found a day with events, increase the daysCollected by 1 - daysCollected++; } + // Increment the daysCollected by one to ensure the while loop does not get stuck. + daysCollected++; // Search for the next day currentDate.add(1, "day"); }