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

Expanding RRule to include 2024 #53

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -176,9 +176,10 @@ function rawParser(rawData) {
//@ts-expect-error
eventsArray.push(rawDataV2[dataValue]); //simplifying results, credits to https://github.com/muness/obsidian-ics for this implementations
} else {
const currentYear = new Date().getFullYear()
const dates = event.rrule.between(
new Date(2021, 0, 1, 0, 0, 0, 0),
new Date(2023, 11, 31, 0, 0, 0, 0)
new Date(currentYear, 11, 31, 0, 0, 0, 0)
);
console.log(dates);
if (dates.length === 0) continue;
Expand Down