From 44562b0c23c04c2ffc21b43b851c7633b40103ca Mon Sep 17 00:00:00 2001 From: kagel Date: Thu, 4 Aug 2016 13:00:17 +0300 Subject: [PATCH] NaN balance fix --- src/cljs/token/wallets/page.cljs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/cljs/token/wallets/page.cljs b/src/cljs/token/wallets/page.cljs index a0e84ab..b0fa996 100644 --- a/src/cljs/token/wallets/page.cljs +++ b/src/cljs/token/wallets/page.cljs @@ -19,7 +19,9 @@ [:div.wallet-name "Another wallet"] [:div.wallet-hash (account-name wallet-id)] [:div.wallet-currencies - [:div.currency-usd [:span.currency "ETH"] (.toFixed (js/parseFloat @balance) 4)]] + [:div.currency-usd [:span.currency "ETH"] + (when-let [balance @balance] + (.toFixed (js/parseFloat balance) 4))]] (wallet-uri wallet-id)]))) (defn wallets []