mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-12-23 09:52:26 +01:00
metamask-controller - fix account lookup hook
This commit is contained in:
parent
91accee2c6
commit
66a62dfd0c
@ -241,7 +241,7 @@ module.exports = class MetamaskController extends EventEmitter {
|
||||
},
|
||||
},
|
||||
// account mgmt
|
||||
getAccounts: (cb) => {
|
||||
getAccounts: async () => {
|
||||
const isUnlocked = this.keyringController.memStore.getState().isUnlocked
|
||||
const result = []
|
||||
const selectedAddress = this.preferencesController.getSelectedAddress()
|
||||
@ -250,7 +250,7 @@ module.exports = class MetamaskController extends EventEmitter {
|
||||
if (isUnlocked && selectedAddress) {
|
||||
result.push(selectedAddress)
|
||||
}
|
||||
cb(null, result)
|
||||
return result
|
||||
},
|
||||
// tx signing
|
||||
// old style msg signing
|
||||
|
Loading…
Reference in New Issue
Block a user