aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPinapelz <yukais@pinapelz.com>2025-04-14 03:15:03 -0700
committerPinapelz <yukais@pinapelz.com>2025-04-14 03:15:03 -0700
commit00deaf24ef1c9e5d75b65638eb8c7c6bc8f09955 (patch)
treed3b983990904fa91bcfe256ee3916bd494b82740
parent073fc8fe92e60fd4662580e8216600379a0edfae (diff)
fix: make gameId lowercase before checking
-rw-r--r--site/src/utils.ts10
1 files changed, 6 insertions, 4 deletions
diff --git a/site/src/utils.ts b/site/src/utils.ts
index e523f5c..270b5a2 100644
--- a/site/src/utils.ts
+++ b/site/src/utils.ts
@@ -1,10 +1,12 @@
export const getGameTitle = (gameId: string) => {
if (!gameId) return null;
- if (gameId.startsWith("sdvx")) return "SOUND VOLTEX";
- if (gameId.startsWith("iidx")) return "beatmania IIDX";
- if (gameId.startsWith("chunithm_jp")) return "CHUNITHM (JAPAN)";
- if (gameId.startsWith("maimaidx_jp")) return "maimai DX (JAPAN)";
+ const lowerCaseGameId = gameId.toLowerCase();
+
+ if (lowerCaseGameId.startsWith("sdvx")) return "SOUND VOLTEX";
+ if (lowerCaseGameId.startsWith("iidx")) return "beatmania IIDX";
+ if (lowerCaseGameId.startsWith("chunithm_jp")) return "CHUNITHM (JAPAN)";
+ if (lowerCaseGameId.startsWith("maimaidx_jp")) return "maimai DX (JAPAN)";
return gameId.toUpperCase();
};
send patches to the email below
yukais@pinapelz.com
include the subject [PATCH repo_name]
pinapelz.com
homepage