From b81690a9fdd49a06a854022602e540ec40a328ca Mon Sep 17 00:00:00 2001 From: PikachuEXE Date: Sat, 23 Sep 2023 21:17:48 +0800 Subject: [PATCH] ! Fix in sub view, restoring last tab is bugged when visible tabs do not include tab to be restored --- src/renderer/views/Subscriptions/Subscriptions.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/renderer/views/Subscriptions/Subscriptions.js b/src/renderer/views/Subscriptions/Subscriptions.js index 8c5749e90af4c..b6bb7244afb61 100644 --- a/src/renderer/views/Subscriptions/Subscriptions.js +++ b/src/renderer/views/Subscriptions/Subscriptions.js @@ -111,7 +111,8 @@ export default defineComponent({ if (this.visibleTabs.includes(tab)) { this.currentTab = tab } else { - this.currentTab = null + // First visible tab or no tab + this.currentTab = this.visibleTabs.length > 0 ? this.visibleTabs[0] : null } },