diff options
author | Fabio Berger <me@fabioberger.com> | 2018-02-07 09:23:01 +0800 |
---|---|---|
committer | Fabio Berger <me@fabioberger.com> | 2018-02-07 09:23:01 +0800 |
commit | 05aa2fa42148e79f6a3dd35e91e9e85346c4d421 (patch) | |
tree | 5c7f1d845fc1fa162958a0b840242eb11e1c23c7 /packages/website/ts/components | |
parent | 03f5c9b9508b833bd4645386b5f46720a7d7ba2a (diff) | |
download | dexon-sol-tools-05aa2fa42148e79f6a3dd35e91e9e85346c4d421.tar.gz dexon-sol-tools-05aa2fa42148e79f6a3dd35e91e9e85346c4d421.tar.zst dexon-sol-tools-05aa2fa42148e79f6a3dd35e91e9e85346c4d421.zip |
Properly detect Rinkeby and Ropsten TokenRegistry tokens as mintable
Diffstat (limited to 'packages/website/ts/components')
-rw-r--r-- | packages/website/ts/components/token_balances.tsx | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/packages/website/ts/components/token_balances.tsx b/packages/website/ts/components/token_balances.tsx index 64aa1ef3f..ea8144b7d 100644 --- a/packages/website/ts/components/token_balances.tsx +++ b/packages/website/ts/components/token_balances.tsx @@ -362,8 +362,14 @@ export class TokenBalances extends React.Component<TokenBalancesProps, TokenBala EtherscanLinkSuffixes.Address, ); const isMintable = - _.includes(configs.SYMBOLS_OF_MINTABLE_TOKENS, token.symbol) && - this.props.networkId !== constants.NETWORK_ID_MAINNET; + (_.includes(configs.SYMBOLS_OF_MINTABLE_KOVAN_TOKENS, token.symbol) && + this.props.networkId === constants.NETWORK_ID_BY_NAME[Networks.Kovan]) || + (_.includes(configs.SYMBOLS_OF_MINTABLE_RINKEBY_ROPSTEN_TOKENS, token.symbol) && + _.includes( + [constants.NETWORK_ID_BY_NAME[Networks.Rinkeby], constants.NETWORK_ID_BY_NAME[Networks.Ropsten]], + this.props.networkId, + )); + console.log('token', token); return ( <TableRow key={token.address} style={{ height: TOKEN_TABLE_ROW_HEIGHT }}> <TableRowColumn colSpan={tokenColSpan}> |