mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-12-23 09:52:26 +01:00
Improving getMemoizedMetadataContractName selector (#17432)
This commit is contained in:
parent
62bca62273
commit
58b5332b67
@ -831,8 +831,9 @@ export const getMemoizedMetadataContractName = createDeepEqualSelector(
|
||||
getTokenList,
|
||||
(_tokenList, address) => address,
|
||||
(tokenList, address) => {
|
||||
const checksumHexAddress = toChecksumHexAddress(address);
|
||||
const entry = Object.values(tokenList).find((identity) =>
|
||||
isEqualCaseInsensitive(identity.address, toChecksumHexAddress(address)),
|
||||
isEqualCaseInsensitive(identity.address, checksumHexAddress),
|
||||
);
|
||||
return entry && entry.name !== '' ? entry.name : '';
|
||||
},
|
||||
|
Loading…
Reference in New Issue
Block a user