From 4a3e23c2888595bd0614444f719ca14605e63681 Mon Sep 17 00:00:00 2001 From: Abdullah Atta Date: Sat, 27 Jul 2024 10:17:12 +0500 Subject: [PATCH] web: fix reminder can't be set in january --- apps/web/src/stores/reminder-store.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/apps/web/src/stores/reminder-store.ts b/apps/web/src/stores/reminder-store.ts index 887819ff71..1ab036521d 100644 --- a/apps/web/src/stores/reminder-store.ts +++ b/apps/web/src/stores/reminder-store.ts @@ -142,12 +142,12 @@ function reminderToCronExpression(reminder: Reminder) { const dateTime = dayjs(date); if (mode === "once" || !selectedDays) { - return dateTime.format("ss mm HH DD MM * YYYY"); + return dateTime.format("00 mm HH DD MM * YYYY"); } else { - const cron = dateTime.format("ss mm HH").split(" "); + const cron = dateTime.format("00 mm HH").split(" "); if (recurringMode === "year") { cron.push(`${dateTime.date()}`); // day of month - cron.push(`${dateTime.month()}`); // month + cron.push(`${dateTime.month() + 1}`); // month cron.push("*"); // day of week cron.push("*"); // year } else if (recurringMode === "week") {