From 9d2a26fa07175238a4020864ebbcc00b36500617 Mon Sep 17 00:00:00 2001 From: Liam Date: Sun, 20 Oct 2024 14:01:47 +0100 Subject: [PATCH] skip 999_999 on fallback data --- projects/common/src/player/impl/scoresaber-player.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/projects/common/src/player/impl/scoresaber-player.ts b/projects/common/src/player/impl/scoresaber-player.ts index 23898b6..af1cfa5 100644 --- a/projects/common/src/player/impl/scoresaber-player.ts +++ b/projects/common/src/player/impl/scoresaber-player.ts @@ -139,6 +139,10 @@ export async function getScoreSaberPlayerFromToken( let daysAgo = 0; // Start from current day for (let i = playerRankHistory.length - 1; i >= 0; i--) { const rank = playerRankHistory[i]; + if (rank == 999_999) { + continue; + } + const date = getMidnightAlignedDate(getDaysAgoDate(daysAgo)); daysAgo += 1;