From a67a5efca394873733e9181d516fbde679d705f6 Mon Sep 17 00:00:00 2001 From: dragana8 <92531782+dragana8@users.noreply.github.com> Date: Wed, 19 Jan 2022 20:04:33 +0100 Subject: [PATCH] Incorrect Rounding Down of Balance #10167 (#13337) --- package.json | 2 +- ui/hooks/useTokenTracker.js | 1 + yarn.lock | 8 ++++---- 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/package.json b/package.json index acaf95868..b2b49116a 100644 --- a/package.json +++ b/package.json @@ -109,7 +109,7 @@ "@metamask/contract-metadata": "^1.31.0", "@metamask/controllers": "^25.0.0", "@metamask/eth-ledger-bridge-keyring": "^0.10.0", - "@metamask/eth-token-tracker": "^3.0.1", + "@metamask/eth-token-tracker": "^4.0.0", "@metamask/etherscan-link": "^2.1.0", "@metamask/jazzicon": "^2.0.0", "@metamask/logo": "^3.1.1", diff --git a/ui/hooks/useTokenTracker.js b/ui/hooks/useTokenTracker.js index 01b56f615..29772a1de 100644 --- a/ui/hooks/useTokenTracker.js +++ b/ui/hooks/useTokenTracker.js @@ -67,6 +67,7 @@ export function useTokenTracker( tokens: tokenList, includeFailedTokens, pollingInterval: SECOND * 8, + balanceDecimals: 5, }); tokenTracker.current.on('update', updateBalances); diff --git a/yarn.lock b/yarn.lock index 036efd66e..14c821966 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2718,10 +2718,10 @@ ethereumjs-util "^7.0.9" hdkey "0.8.0" -"@metamask/eth-token-tracker@^3.0.1": - version "3.1.0" - resolved "https://registry.yarnpkg.com/@metamask/eth-token-tracker/-/eth-token-tracker-3.1.0.tgz#1396c5d88401f3cd598b0c86d3a42951c8e78d73" - integrity sha512-SopDFnIu7lI8aloD9HGPEpqlcjZNzZ5BeXZqrNRSdSO+CGpuwmFoeyrCrgEmrlkKQvP8dQi6R6aYK/itFPhPrg== +"@metamask/eth-token-tracker@^4.0.0": + version "4.0.0" + resolved "https://registry.yarnpkg.com/@metamask/eth-token-tracker/-/eth-token-tracker-4.0.0.tgz#f3129855873a857ef675d4c28f532be684241b61" + integrity sha512-T+InGiclG5JJB1uOhMpzywthuDm2xw+Wiq3Y7UbCDdLHtAWxgAwPlNVAyfjwlbWmf9G/TODzMuYyyxEtynbYJw== dependencies: deep-equal "^1.1.0" eth-block-tracker "^4.4.2"