From 5d35dc9ce7709edb23c683ec219499a1c11d754c Mon Sep 17 00:00:00 2001 From: Richard C Lim <61879224+richardclim@users.noreply.github.com> Date: Mon, 3 Feb 2025 02:29:24 -0500 Subject: [PATCH] Update common.ts --- app/api/common.ts | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/app/api/common.ts b/app/api/common.ts index f276f64b5..c250b5cb4 100644 --- a/app/api/common.ts +++ b/app/api/common.ts @@ -14,14 +14,8 @@ const isAzure = req.nextUrl.pathname.includes("azure/deployments") || Boolean(se var authValue, authHeaderName = ""; if (isAzure) { - authValue = - req.headers - .get("Authorization") - ?.trim() - .replaceAll("Bearer ", "") - .trim() ?? ""; - - authHeaderName = "Authorization"; + authValue = `Bearer ${serverConfig.azureApiKey}`; + authHeaderName = "Authorization"; } else { authValue = req.headers.get("Authorization") ?? ""; authHeaderName = "Authorization";