diff --git a/api/dailies.ts b/api/dailies.ts index 2748a6a..9dfa4ab 100644 --- a/api/dailies.ts +++ b/api/dailies.ts @@ -80,12 +80,11 @@ async function executeDailyWebhook( // Get the daily question. const question = await lcClient.getDailyQuestion(); - // Get the season data if a season ID is provided or if it is the beginning - // of a new season. - const isNewSeason = new Date(`${question.date} GMT`).getDay() === 1; + // Get the season data if a season ID is provided or if it is Sunday. + const isSunday = new Date(question.date).getDay() === 0; const season = seasonID ? await leaderboardClient.getSeason(seasonID) - : isNewSeason + : isSunday ? await leaderboardClient.getCurrentSeason() : null;