Fixed streak not using local time

This commit is contained in:
Maximilian Giller 2024-02-06 20:29:42 +01:00
parent a909aee7a1
commit 2c349422e3

View file

@ -330,7 +330,7 @@
let classes = ["bi"]
const adjustedDate = new Date((new Date()).getTime() - offset * 24 * 60 * 60 * 1000);
const formattedDate = adjustedDate.toISOString().split('T')[0];
const formattedDate = adjustedDate.getFullYear().toString() + "-" + (adjustedDate.getMonth() + 1).toString().padStart(2, "0") + "-" + adjustedDate.getDate().toString().padStart(2, "0");
if (streakData.length > 0) {
if (streakData.includes(formattedDate)) {