From 1cd19c108e6a8bd8ca6b422eb9c1813fbda9e990 Mon Sep 17 00:00:00 2001 From: Gabriel mermelstein Date: Wed, 12 Jun 2024 14:20:31 +0200 Subject: [PATCH] not using localStorage for the API endpoint if an env variable is set --- src/App.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/App.tsx b/src/App.tsx index 8c02da5..9f510fb 100644 --- a/src/App.tsx +++ b/src/App.tsx @@ -73,7 +73,7 @@ function App() { setUsername(name); const endpoint = localStorage.getItem("apiEndpoint"); - if (endpoint) { + if (endpoint && !import.meta.env.VITE_API_ENDPOINT) { setApiEndpoint(endpoint); }