[#378] addressed code rabbit out of scope comments (#422)

Co-authored-by: Camille Moussu <cmoussu@linagora.com>
This commit is contained in:
Camille Moussu
2025-12-16 14:06:16 +01:00
committed by GitHub
parent c81153a119
commit 1a60850637
2 changed files with 4 additions and 5 deletions
+1 -1
View File
@@ -50,7 +50,7 @@ function App() {
const lang =
[userLanguage, settingsLanguage, savedLang, defaultLang].find(
(l): l is string => isValidLanguage(l)
(l) => !!l && isValidLanguage(l)
) || "en";
const dispatch = useAppDispatch();
+3 -4
View File
@@ -992,10 +992,9 @@ function formatEnd(
const startDate = new Date(start);
const endDate = new Date(end);
const sameDay =
startDate.getFullYear() === endDate.getFullYear() &&
startDate.getMonth() === endDate.getMonth() &&
startDate.getDate() === endDate.getDate();
const formatDatePart = (d: Date) =>
d.toLocaleDateString("en-CA", { timeZone }); // YYYY-MM-DD format
const sameDay = formatDatePart(startDate) === formatDatePart(endDate);
if (allday) {
return sameDay