mirror of
https://github.com/cake-tech/cake_wallet.git
synced 2025-06-28 20:39:51 +00:00
fix(polygon): Polygon wallets not showing in address book when sending tokens
This commit is contained in:
parent
21d5c51cc9
commit
4589eb8149
2 changed files with 7 additions and 2 deletions
|
@ -84,6 +84,6 @@ class DefaultPolygonErc20Tokens {
|
|||
.iconPath;
|
||||
} catch (_) {}
|
||||
|
||||
return Erc20Token.copyWith(token, iconPath, 'POLY');
|
||||
return Erc20Token.copyWith(token, iconPath, 'POL');
|
||||
}).toList();
|
||||
}
|
||||
|
|
|
@ -45,7 +45,12 @@ class PolygonWallet extends EVMChainWallet {
|
|||
final initialErc20Tokens = DefaultPolygonErc20Tokens().initialPolygonErc20Tokens;
|
||||
|
||||
for (final token in initialErc20Tokens) {
|
||||
if (!evmChainErc20TokensBox.containsKey(token.contractAddress)) {
|
||||
if (evmChainErc20TokensBox.containsKey(token.contractAddress)) {
|
||||
final existingToken = evmChainErc20TokensBox.get(token.contractAddress);
|
||||
if (existingToken?.tag != token.tag) {
|
||||
evmChainErc20TokensBox.put(token.contractAddress, token);
|
||||
}
|
||||
} else {
|
||||
if (isMigration) token.enabled = false;
|
||||
evmChainErc20TokensBox.put(token.contractAddress, token);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue