Skip to content

Commit

Permalink
Update upcoming event order by imminence #216
Browse files Browse the repository at this point in the history
  • Loading branch information
Freymaurer committed Oct 30, 2024
1 parent e3917ac commit 999dab0
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/components/events/EventList.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,10 @@ export default function EventList( {events, showFilter = true, showPastFutureLim
return true;
}

const filteredUpcomingEvents = upcomingEvents.filter(filterEvents);
const filteredUpcomingEvents =
upcomingEvents
.filter(filterEvents)
.sort((a, b) => a.data.when.start.getTime() - b.data.when.start.getTime());

return (
<>
Expand Down

0 comments on commit 999dab0

Please sign in to comment.