From a64918005e4cd9382cb123d2a1227c2976db1fc5 Mon Sep 17 00:00:00 2001 From: igormuba Date: Fri, 11 Aug 2023 15:40:39 -0300 Subject: [PATCH] remove SNProfileID if no accounts --- src/renderer/views/Accounts.tsx | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/renderer/views/Accounts.tsx b/src/renderer/views/Accounts.tsx index 6b603ee..184c89d 100644 --- a/src/renderer/views/Accounts.tsx +++ b/src/renderer/views/Accounts.tsx @@ -51,6 +51,8 @@ export function AccountsView() { if (accountsInit.length > 0) { localStorage.setItem('SNProfileID', accountsInit[0]._id) + } else { + localStorage.removeItem('SNProfileID') } window.location.reload() }