use current provider for running script

pull/5370/head
yann300 1 year ago
parent 4181e6b7fb
commit 2a2d92a96f
  1. 2
      apps/remix-ide/src/app/plugins/solidity-script.tsx
  2. 2
      apps/remix-ide/src/blockchain/blockchain.tsx

@ -62,7 +62,7 @@ export class SolidityScript extends Plugin {
return
}
const bytecode = '0x' + contract.object.evm.bytecode.object
const web3 = await this.call('blockchain', 'web3VM')
const web3 = await this.call('blockchain', 'web3')
const accounts = await this.call('blockchain', 'getAccounts')
if (!accounts || accounts.length === 0) {
throw new Error('no account available')

@ -23,7 +23,7 @@ const profile = {
name: 'blockchain',
displayName: 'Blockchain',
description: 'Blockchain - Logic',
methods: ['getCode', 'getTransactionReceipt', 'addProvider', 'removeProvider', 'getCurrentFork', 'getAccounts', 'web3VM', 'getProvider'],
methods: ['getCode', 'getTransactionReceipt', 'addProvider', 'removeProvider', 'getCurrentFork', 'getAccounts', 'web3VM', 'web3', 'getProvider'],
version: packageJson.version
}

Loading…
Cancel
Save