From c05e04c611f44ff8bef2f1d617cb79d2a5157f2a Mon Sep 17 00:00:00 2001 From: Dan Finlay Date: Fri, 23 Dec 2016 17:22:46 -0800 Subject: Fix rendering of loose accounts --- ui/app/components/eth-balance.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'ui/app/components/eth-balance.js') diff --git a/ui/app/components/eth-balance.js b/ui/app/components/eth-balance.js index 46127bed5..57ca84564 100644 --- a/ui/app/components/eth-balance.js +++ b/ui/app/components/eth-balance.js @@ -15,9 +15,10 @@ function EthBalanceComponent () { EthBalanceComponent.prototype.render = function () { var props = this.props + let { value } = props var style = props.style var needsParse = this.props.needsParse !== undefined ? this.props.needsParse : true - const value = formatBalance(props.value, 6, needsParse) + value = value ? formatBalance(value, 6, needsParse) : '...' var width = props.width return ( @@ -38,6 +39,7 @@ EthBalanceComponent.prototype.render = function () { EthBalanceComponent.prototype.renderBalance = function (value) { var props = this.props if (value === 'None') return value + if (value === '...') return value var balanceObj = generateBalanceObject(value, props.shorten ? 1 : 3) var balance var splitBalance = value.split(' ') -- cgit