From ed58639d4035195be3860e4ac63603ec58a694e3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Troed=20S=C3=A5ngberg?= Date: Tue, 16 Jun 2026 13:15:05 +0200 Subject: [PATCH] fix: always load provider URLs from config, fallback to localhost --- tui.tsx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tui.tsx b/tui.tsx index 75d6a77..bda7c6f 100644 --- a/tui.tsx +++ b/tui.tsx @@ -280,7 +280,7 @@ const tui: TuiPlugin = async (api) => { bump() } - let llamaServerUrls: string[] = ["http://localhost:8080"] + let llamaServerUrls: string[] = [] let llamaServerModel: string | undefined const pollMetrics = async () => { @@ -508,11 +508,11 @@ const tui: TuiPlugin = async (api) => { }) try { - if (!llamaServerUrls.length) { - llamaServerUrls = await loadConfigUrls(api) - } + const configUrls = await loadConfigUrls(api) + llamaServerUrls = configUrls.length > 0 ? configUrls : ["http://localhost:8080"] } catch (e) { console.error("[oc-ls-stats] loadConfigUrls error:", e) + llamaServerUrls = ["http://localhost:8080"] } api.slots.register({