Skip to content

Commit

Permalink
fix(events): fix camus life event filtering logic
Browse files Browse the repository at this point in the history
  • Loading branch information
Robert27 committed Dec 14, 2024
1 parent a180834 commit eb259d2
Showing 1 changed file with 2 additions and 7 deletions.
9 changes: 2 additions & 7 deletions src/utils/events-utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,13 +29,8 @@ export async function loadCampusLifeEvents(): Promise<
begin: x.startDateTime != null ? new Date(x.startDateTime) : null,
end: x.endDateTime != null ? new Date(x.endDateTime) : null,
}))
.filter(
(x) =>
x.end === null ||
x.end > new Date() ||
x.titles.de !== '' ||
x.titles.en !== ''
)
.filter((x) => x.end == null || x.end > new Date())
.filter((x) => x.titles.de !== '' || x.titles.en !== '')
return newEvents
}

Expand Down

0 comments on commit eb259d2

Please sign in to comment.