updated with new API of web3.js

pull/5370/head
lianahus 3 years ago committed by yann300
parent 6ad42ea1ab
commit 9d6b4ce346
  1. 2
      apps/remix-ide/src/blockchain/providers/injected.js
  2. 4
      apps/remix-ide/src/blockchain/providers/node.js

@ -12,7 +12,7 @@ class InjectedProvider {
newAccount (passwordPromptCb, cb) {
passwordPromptCb((passphrase) => {
this.executionContext.web3().personal.newAccount(passphrase, cb)
this.executionContext.web3().eth.personal.newAccount(passphrase, cb)
})
}

@ -10,7 +10,7 @@ class NodeProvider {
getAccounts (cb) {
if (this.config.get('settings/personal-mode')) {
return this.executionContext.web3().personal.getListAccounts(cb)
return this.executionContext.web3().eth.personal.getAccounts(cb)
}
return this.executionContext.web3().eth.getAccounts(cb)
}
@ -20,7 +20,7 @@ class NodeProvider {
return cb('Not running in personal mode')
}
passwordPromptCb((passphrase) => {
this.executionContext.web3().personal.newAccount(passphrase, cb)
this.executionContext.web3().eth.personal.newAccount(passphrase, cb)
})
}

Loading…
Cancel
Save