mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-12-23 09:52:26 +01:00
Checksum address before slicing it for the confirm screen (#6133)
This commit is contained in:
parent
8dddf48904
commit
1d8d129305
@ -17,7 +17,7 @@ import { getHexGasTotal } from '../../../helpers/confirm-transaction/util'
|
||||
import { isBalanceSufficient, calcGasTotal } from '../../send/send.utils'
|
||||
import { conversionGreaterThan } from '../../../conversion-util'
|
||||
import { MIN_GAS_LIMIT_DEC } from '../../send/send.constants'
|
||||
import { addressSlicer, valuesFor } from '../../../util'
|
||||
import { checksumAddress, addressSlicer, valuesFor } from '../../../util'
|
||||
import { getMetaMaskAccounts, getAdvancedInlineGasShown } from '../../../selectors'
|
||||
|
||||
const casedContractMap = Object.keys(contractMap).reduce((acc, base) => {
|
||||
@ -77,7 +77,11 @@ const mapStateToProps = (state, props) => {
|
||||
const toAddress = propsToAddress || txParamsToAddress
|
||||
const toName = identities[toAddress]
|
||||
? identities[toAddress].name
|
||||
: casedContractMap[toAddress] ? casedContractMap[toAddress].name : addressSlicer(toAddress)
|
||||
: (
|
||||
casedContractMap[toAddress]
|
||||
? casedContractMap[toAddress].name
|
||||
: addressSlicer(checksumAddress(toAddress))
|
||||
)
|
||||
|
||||
const isTxReprice = Boolean(lastGasPrice)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user