fix App is not opened on the last viewed chat with biometric login enabled (#16516)

This commit is contained in:
Parvesh Monu 2023-07-10 15:33:31 +05:30 committed by GitHub
parent 9ac14b6fac
commit 728d9d01c5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 10 deletions

View File

@ -198,16 +198,8 @@
:key-uid (get-in cofx [:db :profile/profile :key-uid])}
:db (assoc db :screens/was-focused-once? true)}
(= :login view-id)
{}
(not (get db :screens/was-focused-once?))
{:db (assoc db :screens/was-focused-once? true)}
:else
{::async-storage/set! {:chat-id nil
:key-uid nil}
:db (assoc db :screens/was-focused-once? true)})
{:db (assoc db :screens/was-focused-once? true)})
#(case view-id
:keycard-settings (keycard/settings-screen-did-load %)
:reset-card (keycard/reset-card-screen-did-load %)

View File

@ -174,7 +174,9 @@
(chat.state/reset-visible-item)
(rf/merge cofx
(merge
{:db (dissoc db :current-chat-id)}
{:db (dissoc db :current-chat-id)
::async-storage/set! {:chat-id nil
:key-uid nil}}
(let [community-id (get-in db [:chats chat-id :community-id])]
;; When navigating back from community chat to community, update switcher card
;; A close chat event is also called while opening any chat.