azza-bazoo / prettycron

Display cron runspecs in human-readable format

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Wrong day of the week displayed

mehtasankets opened this issue · comments

When used 7 for Sunday (cron entry accepts 0 as well as 7 for Sunday), the cron entry still prints Saturday.

console.log('cron entry for Saturday: ', prettyCron.toString('30 13 * * 6'));
This one correctly prints "cron entry for Saturday: 13:30 on Sat"

console.log('cron entry for Sunday: ', prettyCron.toString('30 13 * * 7'));
This one also prints "cron entry for Sunday: 13:30 on Sat" Where as it should have been "cron entry for Sunday: 13:30 on Sun"