From 4129ca1597f0f6fb19d5b2ac4318b88bef8e6e92 Mon Sep 17 00:00:00 2001 From: Roman Volosovskyi Date: Tue, 13 Apr 2021 16:33:34 +0300 Subject: [PATCH] [wallet #11898] Fix disappearing tokens after adding a new account --- src/status_im/wallet/core.cljs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/status_im/wallet/core.cljs b/src/status_im/wallet/core.cljs index ac7cd90f0c..e65d2fceaa 100644 --- a/src/status_im/wallet/core.cljs +++ b/src/status_im/wallet/core.cljs @@ -27,7 +27,8 @@ status-im.wallet.recipient.core [status-im.ui.screens.wallet.signing-phrase.views :as signing-phrase] [status-im.async-storage.core :as async-storage] - [status-im.popover.core :as popover.core])) + [status-im.popover.core :as popover.core] + [clojure.set :as clojure.set])) (defn get-balance [{:keys [address on-success on-error]}] @@ -326,9 +327,8 @@ (flatten (map keys (vals balances))))] (fx/merge cofx (multiaccounts.update/multiaccount-update - :wallet/visible-tokens (assoc visible-tokens - chain - chain-visible-tokens) + :wallet/visible-tokens + (update visible-tokens chain clojure.set/union chain-visible-tokens) {}) (update-tokens-balances balances) (prices/update-prices))))