(Fix) change error message Contract address input (#2060)
* change error message Contract address input
This commit is contained in:
parent
da9031568f
commit
4297671869
|
@ -80,9 +80,7 @@ export const mustBeEthereumContractAddress = memoize(
|
|||
async (address: string): Promise<ValidatorReturnType> => {
|
||||
const contractCode = await getWeb3().eth.getCode(address)
|
||||
|
||||
const errorMessage = `Input must be a valid Ethereum contract address${
|
||||
isFeatureEnabled(FEATURES.DOMAIN_LOOKUP) ? ', ENS or Unstoppable domain' : ''
|
||||
}`
|
||||
const errorMessage = `Must resolve to a valid smart contract address.`
|
||||
|
||||
return !contractCode || contractCode.replace('0x', '').replace(/0/g, '') === '' ? errorMessage : undefined
|
||||
},
|
||||
|
|
Loading…
Reference in New Issue