fix(chats): Fix chats leaking to other profile (#21713)
Fixes a regression introduced in PR https://github.com/status-im/status-mobile/pull/21634. What's important is that the fix for chats leaking to other profiles was a client-side bug, thus not coming from status-go, thus no private data was leaking to other profiles. This PR keeps the existing workaround to memoize chats in the home screen. Fixes https://github.com/status-im/status-mobile/issues/21696
This commit is contained in:
parent
3a444f40f3
commit
d0deb94bf3
|
@ -14,8 +14,11 @@
|
|||
network/status network/expensive?
|
||||
centralized-metrics/user-confirmed?]
|
||||
network-type :network/network-type
|
||||
:as _db}]
|
||||
:as db}]
|
||||
(assoc db/app-db
|
||||
;; We must carry over the current `:selected-stack-id`, otherwise the
|
||||
;; app will start with `:view-id` as nil.
|
||||
:shell/selected-stack-id (:shell/selected-stack-id db)
|
||||
:profile/logging-out? true
|
||||
:centralized-metrics/user-confirmed? user-confirmed?
|
||||
:network/type network-type
|
||||
|
@ -44,4 +47,3 @@
|
|||
[:dispatch-later
|
||||
{:ms 100
|
||||
:dispatch [:profile.logout/reset-state]}]]}))
|
||||
|
||||
|
|
|
@ -9,7 +9,6 @@
|
|||
[native-module.core :as native-module]
|
||||
[re-frame.core :as re-frame]
|
||||
[re-frame.interop :as interop]
|
||||
[react-native.async-storage :as async-storage]
|
||||
[react-native.core :as rn]
|
||||
[react-native.platform :as platform]
|
||||
[react-native.shake :as react-native-shake]
|
||||
|
@ -60,9 +59,6 @@
|
|||
(universal-links/initialize)
|
||||
(interceptors/register-global-interceptors)
|
||||
|
||||
;; Shell
|
||||
(async-storage/get-item :selected-stack-id #(re-frame/dispatch [:shell/change-tab %]))
|
||||
|
||||
(when config/quo-preview-enabled?
|
||||
(ff/load-flags))
|
||||
|
||||
|
|
|
@ -62,6 +62,9 @@
|
|||
(rf/merge
|
||||
cofx
|
||||
{:db db/app-db
|
||||
:effects.async-storage/get {:keys [:selected-stack-id]
|
||||
:cb (fn [{:keys [selected-stack-id]}]
|
||||
(rf/dispatch [:shell/change-tab selected-stack-id]))}
|
||||
:theme/init-theme nil
|
||||
:effects.network/listen-to-network-info nil
|
||||
:effects.biometric/get-supported-type nil
|
||||
|
|
Loading…
Reference in New Issue