From f710d35fc8c898356368758bee972d58e1981d63 Mon Sep 17 00:00:00 2001 From: Emir Karabeg <78010029+emir-karabeg@users.noreply.github.com> Date: Tue, 18 Feb 2025 22:04:39 -0800 Subject: [PATCH] fix(bug): deployment with route (#70) --- app/api/settings/environment/route.ts | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/app/api/settings/environment/route.ts b/app/api/settings/environment/route.ts index 137e8d3b6..a0a7d54d7 100644 --- a/app/api/settings/environment/route.ts +++ b/app/api/settings/environment/route.ts @@ -71,13 +71,10 @@ export async function GET(request: Request) { return NextResponse.json({ data: {} }, { status: 200 }) } - // Parse the variables and return just the structure without the hashed values - const variables = result[0].variables as Record + // Update the type handling for variables + const variables = result[0].variables as Record const sanitizedVariables = Object.fromEntries( - Object.entries(variables).map(([key, value]) => [ - key, - { key, value: '••••••••' }, // Hide the actual value - ]) + Object.entries(variables).map(([key, value]) => [key, { key, value: '••••••••' }]) ) return NextResponse.json({ data: sanitizedVariables }, { status: 200 })