From 94e3fe93cf8aae6740dba9735db6b941c5d13eb6 Mon Sep 17 00:00:00 2001 From: Artem Bulgakov Date: Sun, 18 Feb 2024 16:13:49 +0300 Subject: [PATCH] fix: some events are not showing on the calendar Fixes #126 --- components/common/calendar/Calendar.tsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/components/common/calendar/Calendar.tsx b/components/common/calendar/Calendar.tsx index d329551..927b0c6 100644 --- a/components/common/calendar/Calendar.tsx +++ b/components/common/calendar/Calendar.tsx @@ -65,8 +65,9 @@ function Calendar({ // Accumulate 'extendedProps.calendarURLs' to use it later. const unique: Record = {}; for (const event of events) { + // Using 'id' instead of 'title' is a fix for Music romm const uniqueId = - event.id || event.title + event.startStr + event.endStr; + (event.id || event.title) + event.startStr + event.endStr; if (!(uniqueId in unique)) { unique[uniqueId] = event; } else {