From 6ce59ecbd983bccbf24ca3c7f4c2cbf42d78a41d Mon Sep 17 00:00:00 2001 From: Sirz Benjie <142067137+SirzBenjie@users.noreply.github.com> Date: Mon, 15 Sep 2025 19:49:18 -0500 Subject: [PATCH] [Bug] Cookies being fetched improperly --- src/utils/cookies.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/utils/cookies.ts b/src/utils/cookies.ts index e82895d1fac..49c47437241 100644 --- a/src/utils/cookies.ts +++ b/src/utils/cookies.ts @@ -25,9 +25,9 @@ export function getCookie(cName: string): string { const ca = document.cookie.split(";"); // Check all cookies in the document and see if any of them match, grabbing the first one whose value lines up for (const c of ca) { - const cTrimmed = c.trim(); + const cTrimmed = c.trimStart(); if (cTrimmed.startsWith(name)) { - return c.slice(name.length, c.length); + return c.substring(name.length, c.length); } } return "";