Refresh token balances after adding custom token

Signed-off-by: Andrey Shovkoplyas <motor4ik@gmail.com>
This commit is contained in:
acolytec3 2019-12-11 09:36:34 -05:00 committed by Andrey Shovkoplyas
parent 3b65fddb2f
commit 31f7b09a7b
No known key found for this signature in database
GPG Key ID: EAAB7C8622D860A4
1 changed files with 3 additions and 1 deletions

View File

@ -334,7 +334,9 @@
(let [chain (ethereum/chain-keyword db) (let [chain (ethereum/chain-keyword db)
settings (update-toggle-in-settings cofx symbol true) settings (update-toggle-in-settings cofx symbol true)
new-settings (assoc-in settings [:wallet :custom-tokens chain address] token)] new-settings (assoc-in settings [:wallet :custom-tokens chain address] token)]
(multiaccounts.update/update-settings cofx new-settings {}))) (fx/merge cofx
(multiaccounts.update/update-settings cofx new-settings {})
(update-balances nil))))
(fx/defn remove-custom-token (fx/defn remove-custom-token
[{:keys [db] :as cofx} {:keys [symbol address]}] [{:keys [db] :as cofx} {:keys [symbol address]}]