From a9272e40f9a561cd756304f90b07858b6b2607ed Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Fedor?= Date: Wed, 11 Dec 2024 15:58:24 +0100 Subject: [PATCH] Handle svelte errors --- src/js/Content/Modules/Widgets/ITADSync/ITADSyncMenu.svelte | 2 +- src/js/Options/Modules/Options/ITADOptions.svelte | 2 +- src/js/Options/Modules/Options/Settings/ITADConnection.svelte | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/js/Content/Modules/Widgets/ITADSync/ITADSyncMenu.svelte b/src/js/Content/Modules/Widgets/ITADSync/ITADSyncMenu.svelte index ef0a8b942..0b42d7783 100644 --- a/src/js/Content/Modules/Widgets/ITADSync/ITADSyncMenu.svelte +++ b/src/js/Content/Modules/Widgets/ITADSync/ITADSyncMenu.svelte @@ -8,7 +8,7 @@ const itadLogo = ExtensionResources.getURL("img/itad.png"); let statusComponent: ITADSyncStatus; - let status: ESyncStatus; + let status: ESyncStatus|undefined = undefined; diff --git a/src/js/Options/Modules/Options/ITADOptions.svelte b/src/js/Options/Modules/Options/ITADOptions.svelte index b1d44ab43..32bb5f4af 100644 --- a/src/js/Options/Modules/Options/ITADOptions.svelte +++ b/src/js/Options/Modules/Options/ITADOptions.svelte @@ -27,7 +27,7 @@ import type {TSyncEvent} from "@Background/Modules/IsThereAnyDeal/_types"; let settings: Writable = writable(Settings); - let isConnected: boolean; + let isConnected: boolean = false; let events: TSyncEvent[]; diff --git a/src/js/Options/Modules/Options/Settings/ITADConnection.svelte b/src/js/Options/Modules/Options/Settings/ITADConnection.svelte index 92378377a..fc11149e2 100644 --- a/src/js/Options/Modules/Options/Settings/ITADConnection.svelte +++ b/src/js/Options/Modules/Options/Settings/ITADConnection.svelte @@ -26,7 +26,7 @@ let promise: Promise; let statusComponent: ITADSyncStatus; - let status: ESyncStatus; + let status: ESyncStatus|undefined = undefined; function handleAuthorize(): void { promise = (async () => {