From e89540fd94d38e0615fa0498c041fcff6f87e31e Mon Sep 17 00:00:00 2001 From: Mark Stacey Date: Wed, 27 May 2020 22:33:59 -0300 Subject: [PATCH] Fix token `decimal` type (#8670) The `decimals` property of tokens was being set as a string instead of a Number for any tokens added via `getTokenParams`. It's now cast to a Number instead. --- ui/app/store/actions.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ui/app/store/actions.js b/ui/app/store/actions.js index e61e1bb31..71e9bfce8 100644 --- a/ui/app/store/actions.js +++ b/ui/app/store/actions.js @@ -2216,7 +2216,7 @@ export function getTokenParams (tokenAddress) { return fetchSymbolAndDecimals(tokenAddress, existingTokens) .then(({ symbol, decimals }) => { - dispatch(addToken(tokenAddress, symbol, decimals)) + dispatch(addToken(tokenAddress, symbol, Number(decimals))) dispatch(loadingTokenParamsFinished()) }) }