use addressToString for all

pull/4511/head
yann300 9 months ago
parent 778007dbac
commit efb2ec16af
  1. 7
      apps/remix-ide/src/app/tabs/web3-provider.js

@ -55,11 +55,12 @@ export class Web3ProviderModule extends Plugin {
console.log('receipt available but contract address not present', receipt)
return
}
const contractData = await this.call('compilerArtefacts', 'getContractDataFromAddress', receipt.contractAddress)
const contractAddressStr = addressToString(receipt.contractAddress)
const contractData = await this.call('compilerArtefacts', 'getContractDataFromAddress', contractAddressStr)
if (contractData) {
this.call('udapp', 'addInstance', receipt.contractAddress, contractData.contract.abi, contractData.name)
this.call('udapp', 'addInstance', contractAddressStr, contractData.contract.abi, contractData.name)
const data = await this.call('compilerArtefacts', 'getCompilerAbstract', contractData.file)
await this.call('compilerArtefacts', 'addResolvedContract', addressToString(receipt.contractAddress), data)
await this.call('compilerArtefacts', 'addResolvedContract', contractAddressStr, data)
}
}, 50)
}

Loading…
Cancel
Save