From 820734c251ca3d3a9a0a17e7007d223905715635 Mon Sep 17 00:00:00 2001 From: Adrien Date: Fri, 10 Apr 2026 13:55:05 +0200 Subject: [PATCH] fix api url setup --- frontend/src/env.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/frontend/src/env.ts b/frontend/src/env.ts index a413ed4..1adc581 100644 --- a/frontend/src/env.ts +++ b/frontend/src/env.ts @@ -4,5 +4,7 @@ * At build time (dev / CI), values come from import.meta.env. */ export function env(key: string): string | undefined { - return (window as Record).__env__?.[key] ?? (import.meta.env as Record)[key] + const runtime = (window as Record).__env__?.[key] + if (runtime) return runtime + return (import.meta as any).env?.[key] }