diff --git a/src/lib/components/chat/Settings/Images.svelte b/src/lib/components/chat/Settings/Images.svelte index a2be0ab4..cf64b7d4 100644 --- a/src/lib/components/chat/Settings/Images.svelte +++ b/src/lib/components/chat/Settings/Images.svelte @@ -27,7 +27,7 @@ let AUTOMATIC1111_BASE_URL = ''; let selectedModel = ''; - let models = []; + let models = null; let imageSize = ''; let steps = 50; @@ -35,7 +35,7 @@ const getModels = async () => { models = await getDiffusionModels(localStorage.token).catch((error) => { toast.error(error); - return []; + return null; }); selectedModel = await getDefaultDiffusionModel(localStorage.token).catch((error) => { return ''; @@ -198,7 +198,7 @@ {#if !selectedModel} {/if} - {#each models as model} + {#each models ?? [] as model}