Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Parsing "@monthly" returns a months array of [0] #323

Closed
zachsents opened this issue Aug 27, 2024 · 1 comment · Fixed by #324
Closed

Parsing "@monthly" returns a months array of [0] #323

zachsents opened this issue Aug 27, 2024 · 1 comment · Fixed by #324

Comments

@zachsents
Copy link
Contributor

Like title says. Other macros like @hourly and @daily work correctly.

See this snippet:

import { parseCronExpression } from "cron-schedule"

parseCronExpression("@monthly").months
// [ 0 ]

parseCronExpression("0 0 1 * *").months
// [ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11 ]

parseCronExpression("@hourly").months
// [ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11 ]
@zachsents zachsents changed the title Parsing "@monthly" returns an a months array of [0] Parsing "@monthly" returns a months array of [0] Aug 27, 2024
@zachsents
Copy link
Contributor Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant