If you create a rule with an end date, then call between(new Date(), some date after the end date), you get back an empty array
Example
const rule = new RRule({
dstart: new Date('2022-07-08T00:00:00.000Z'),
until: new Date('2022-08-25T00:00:00.000Z'),
freq: RRule.WEEKLY,
interval: 1,
byweekday: [0, 4],
});
console.log(rule.between(new Date(), new Date('2022-08-24T00:00:00.000Z'))) // Array of dates
console.log(rule.between(new Date(), new Date('2022-08-26T00:00:00.000Z'))) // Expect an array of dates but get empty array
Version: 2.6.4 (Latest version has bugs with timezones)
Timezone: BST
Thank you for taking an interest in rrule! Please include the following in
your report:
[x] Verify that you've looked through existing issues for duplicates before
creating a new one
[x] Code sample reproducing the issue. Be sure to include all input values you
are using such as the exact RRule string and dates.
[x] Expected output
[x] Actual output
[x] The version of rrule you are using
[x] Your operating system
[x] Your local timezone (run $ date from the command line
of the machine showing the bug)
Reporting an issue
If you create a rule with an end date, then call
between(new Date(), some date after the end date)
, you get back an empty arrayExample
Version: 2.6.4 (Latest version has bugs with timezones) Timezone: BST
Thank you for taking an interest in
rrule
! Please include the following in your report:rrule
you are using$ date
from the command line of the machine showing the bug)