From 05ee9fbd2a2dfd80d1c5ac62e79355259d1858b0 Mon Sep 17 00:00:00 2001 From: jtydhr88 Date: Fri, 19 May 2023 21:43:02 -0400 Subject: [PATCH] bug fix --- packages/stablestudio-plugin-webui/src/index.ts | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/packages/stablestudio-plugin-webui/src/index.ts b/packages/stablestudio-plugin-webui/src/index.ts index 2f4faf8..b1677ce 100644 --- a/packages/stablestudio-plugin-webui/src/index.ts +++ b/packages/stablestudio-plugin-webui/src/index.ts @@ -152,7 +152,11 @@ export const createPlugin = StableStudio.createPlugin<{ } } - const webuiHostUrl = localStorage.getItem("webui-host-url") ?? "http://127.0.0.1:7861"; + let webuiHostUrl = localStorage.getItem("webui-host-url"); + + if (webuiHostUrl === "" || !webuiHostUrl) { + webuiHostUrl = "http://127.0.0.1:7861"; + } return { ...webuiLoad(webuiHostUrl),