master
James Clarke 2025-03-06 11:30:17 +00:00
parent edb3e9878a
commit df3777bf92
1 changed files with 4 additions and 3 deletions

View File

@ -44,11 +44,12 @@ function formatDay(date) {
return formattedDate; return formattedDate;
} }
const today = new Date(Date.now()); const today = new Date(Date.now());
if (date.getDay() == today.getDay() && date.getMonth() == today.getMonth()) if (date.getDate() == today.getDate())
return /*LANG*/"Today "; return /*LANG*/"Today ";
else { else {
const tomorrow = new Date(Date.now() + 86400 * 1000); const tomorrow = new Date(Date.now());
if (date.getDay() == tomorrow.getDay() && date.getMonth() == tomorrow.getMonth()) { tomorrow.setDate(today.getDate + 1);
if (date.getDate() == tomorrow.getDate()) {
return /*LANG*/"Tomorrow "; return /*LANG*/"Tomorrow ";
} }
return formattedDate; return formattedDate;