mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-12-22 17:33:23 +01:00
Lint.
This commit is contained in:
parent
5afaebe602
commit
121af0c4b9
@ -46,15 +46,16 @@ EthBalanceComponent.prototype.render = function () {
|
|||||||
EthBalanceComponent.prototype.renderBalance = function (value, state) {
|
EthBalanceComponent.prototype.renderBalance = function (value, state) {
|
||||||
if (value === 'None') return value
|
if (value === 'None') return value
|
||||||
var balanceObj = generateBalanceObject(value, state.shorten ? 1 : 3)
|
var balanceObj = generateBalanceObject(value, state.shorten ? 1 : 3)
|
||||||
var balance
|
var balance, fiatNumber
|
||||||
var splitBalance = value.split(' ')
|
var splitBalance = value.split(' ')
|
||||||
var ethNumber = splitBalance[0]
|
var ethNumber = splitBalance[0]
|
||||||
var ethSuffix = splitBalance[1]
|
var ethSuffix = splitBalance[1]
|
||||||
|
|
||||||
|
|
||||||
if (state.conversionRate !== 'N/A') {
|
if (state.conversionRate !== 'N/A') {
|
||||||
var fiatNumber = (Number(splitBalance[0]) * state.conversionRate).toFixed(2)
|
fiatNumber = (Number(splitBalance[0]) * state.conversionRate).toFixed(2)
|
||||||
} else {
|
} else {
|
||||||
var fiatNumber = 'N/A'
|
fiatNumber = 'N/A'
|
||||||
}
|
}
|
||||||
|
|
||||||
var fiatSuffix = state.currentFiat
|
var fiatSuffix = state.currentFiat
|
||||||
@ -100,7 +101,7 @@ EthBalanceComponent.prototype.renderBalance = function (value, state) {
|
|||||||
position: 'bottom',
|
position: 'bottom',
|
||||||
title: `${fiatNumber} ${fiatSuffix}`,
|
title: `${fiatNumber} ${fiatSuffix}`,
|
||||||
}, [
|
}, [
|
||||||
fiatDisplay (fiatNumber, fiatSuffix)
|
fiatDisplay(fiatNumber, fiatSuffix),
|
||||||
]),
|
]),
|
||||||
])
|
])
|
||||||
)
|
)
|
||||||
|
Loading…
Reference in New Issue
Block a user