diff --git a/apps/etherscan/src/app/utils/scripts.ts b/apps/etherscan/src/app/utils/scripts.ts index 70f3619780..1e7765c272 100644 --- a/apps/etherscan/src/app/utils/scripts.ts +++ b/apps/etherscan/src/app/utils/scripts.ts @@ -2,7 +2,7 @@ export const verifyScript = ` /** * @param {string} apikey - etherscan api key. * @param {string} contractAddress - Address of the contract to verify. - * @param {string} contractArguments - Parameters used in the contract constructor during the initial deployment. + * @param {string} contractArguments - Parameters used in the contract constructor during the initial deployment. It should be the hex encoded value. * @param {string} contractName - Name of the contract * @param {string} contractFile - File where the contract is located * @returns {{ guid, status, message, succeed }} verification result diff --git a/apps/etherscan/src/app/utils/verify.ts b/apps/etherscan/src/app/utils/verify.ts index 2d7cab44db..e3cfabd9d9 100644 --- a/apps/etherscan/src/app/utils/verify.ts +++ b/apps/etherscan/src/app/utils/verify.ts @@ -76,7 +76,7 @@ export const verify = async ( sourceCode: JSON.stringify(jsonInput), contractname: fileName + ':' + contractName, compilerversion: `v${contractMetadataParsed.compiler.version}`, // see http://etherscan.io/solcversions for list of support versions - constructorArguements: contractArgumentsParam, // if applicable + constructorArguements: contractArgumentsParam ? contractArgumentsParam.replace('0x', '') : '', // if applicable } const body = new FormData()