Fix creating, editing automations that start weekly on Sunday

This commit is contained in:
Debanjum Singh Solanky 2024-08-11 13:44:35 +05:30
parent ec9add9a51
commit f2f37ae444

View file

@ -554,7 +554,8 @@ function EditCard(props: EditCardProps) {
? String(rawHourAsNumber + 12) ? String(rawHourAsNumber + 12)
: rawHourAsNumber; : rawHourAsNumber;
const dayOfWeekNumber = dayOfWeek ? dayOfWeek : "*"; // Convert Sunday to 0th (from 7th) day of week for server cron format
const dayOfWeekNumber = dayOfWeek !== undefined ? (dayOfWeek === 7 ? 0 : dayOfWeek) : "*";
switch (frequency) { switch (frequency) {
case "Day": case "Day":