From efa82fb9080ea2e07182290200f68d8cd1783d05 Mon Sep 17 00:00:00 2001 From: Nikita Tsymbal Date: Mon, 24 Aug 2026 05:44:10 +0200 Subject: [PATCH] fix(settings): crash when closing the Directory Page settings dialog Closing the Directory Page settings dialog crashed with 'Cannot set properties of null (setting tsMode)': the close handler called pagesStore.getPageById('d0'), but the pages store only holds type === 'page' entries, so the lookup toasted 'error: page not found' and threw. The throw also skipped emit('close-settings'), leaving settingsPageId set in App2, so no settings dialog could be opened again until a full reload. Guard the tsMode sync with the existing _isDir flag, mirroring the label computed above; directory pages have no time slot mode to sync. --- src/components/settings-v2/Settings.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/settings-v2/Settings.vue b/src/components/settings-v2/Settings.vue index 916b2fb9..77eca291 100644 --- a/src/components/settings-v2/Settings.vue +++ b/src/components/settings-v2/Settings.vue @@ -62,7 +62,7 @@ onMounted(() => { const handleUpdateOpen = (evt) => { if (evt === false) { settingsStore.cancelServiceRequest(CK.SETTINGS) - if (pageSettingsLoaded) { + if (pageSettingsLoaded && !_isDir) { pagesStore.getPageById(props.pageId).tsMode = settingsStore.settings.tsMode } emit('close-settings')