Update state for web3 script

pull/4529/head
ioedeveloper 11 months ago
parent d236c64633
commit f5581128da
  1. 7
      apps/remix-ide/src/app/tabs/web3-provider.js

@ -63,6 +63,13 @@ export class Web3ProviderModule extends Plugin {
await this.call('compilerArtefacts', 'addResolvedContract', contractAddressStr, data)
}
}, 50)
const isVM = this.blockchain.executionContext.isVM()
if (isVM) {
await this.blockchain.executionContext.getStateDetails().then((state) => {
this.call('fileManager', 'writeFile', `.states/${this.blockchain.executionContext.getProvider()}/state.json`, state)
})
}
}
}
resolve(message)

Loading…
Cancel
Save