From 97f37702e1cdb3b252bab0aa2930d100321a4511 Mon Sep 17 00:00:00 2001 From: Timothy-Gonzalez <105177619+Timothy-Gonzalez@users.noreply.github.com> Date: Sun, 5 Nov 2023 11:54:22 -0600 Subject: [PATCH] Rename value to be more intuitive --- src/services/auth/auth-lib.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/services/auth/auth-lib.ts b/src/services/auth/auth-lib.ts index e0f288fc..51578a45 100644 --- a/src/services/auth/auth-lib.ts +++ b/src/services/auth/auth-lib.ts @@ -313,17 +313,17 @@ export function getDevice(kv?: string): string { // Replace everything before/after the first equal with nothing, to get KV pairs const key: string = kv.replace(/=.*/, ""); - const value: string = kv.replace(/.*=/, ""); + const possibleDevice: string = kv.replace(/.*=/, ""); if (!key || key != "device") { throw new Error("NoKey"); } - if (!value || !Config.REDIRECT_URLS.has(value)) { + if (!possibleDevice || !Config.REDIRECT_URLS.has(possibleDevice)) { throw new Error("NoValue"); } - return value; + return possibleDevice; } /**