mirror of
https://github.com/fullstack-cash/fullstack-gatsby-theme-bch-wallet.git
synced 2026-09-21 16:52:06 -07:00
feat(token-card): Round tokens to appropriate decimal
This commit is contained in:
@@ -70,9 +70,8 @@ class TokenCard extends React.Component {
|
||||
}
|
||||
|
||||
round (value, decimals) {
|
||||
return Number(Math.round(value+`e${decimals}`)+`e-${decimals}`);
|
||||
return Number(Math.round(value + `e${decimals}`) + `e-${decimals}`)
|
||||
}
|
||||
|
||||
}
|
||||
TokenCard.propTypes = {
|
||||
token: PropTypes.object.isRequired,
|
||||
|
||||
Reference in New Issue
Block a user