aboutsummaryrefslogtreecommitdiffstats
path: root/ui/app/components/pending-tx
diff options
context:
space:
mode:
Diffstat (limited to 'ui/app/components/pending-tx')
-rw-r--r--ui/app/components/pending-tx/confirm-send-token.js6
1 files changed, 4 insertions, 2 deletions
diff --git a/ui/app/components/pending-tx/confirm-send-token.js b/ui/app/components/pending-tx/confirm-send-token.js
index 3b8ae7f7f..f14da38ef 100644
--- a/ui/app/components/pending-tx/confirm-send-token.js
+++ b/ui/app/components/pending-tx/confirm-send-token.js
@@ -15,6 +15,9 @@ const {
multiplyCurrencies,
addCurrencies,
} = require('../../conversion-util')
+const {
+ calcTokenAmount,
+} = require('../../token-util')
const { MIN_GAS_PRICE_HEX } = require('../send/send-constants')
@@ -73,8 +76,7 @@ ConfirmSendToken.prototype.getAmount = function () {
const { params = [] } = tokenData
const { value } = params[1] || {}
const { decimals } = token
- const multiplier = Math.pow(10, Number(decimals || 0))
- const sendTokenAmount = Number(value / multiplier)
+ const sendTokenAmount = calcTokenAmount(value, decimals)
return {
fiat: tokenExchangeRate