Clear old seed words when importing new seed words

feature/default_network_editable
Whymarrh Whitby 6 years ago
parent fdb023381b
commit 8541442b8d
  1. 8
      ui/app/actions.js

@ -413,7 +413,12 @@ function createNewVaultAndRestore (password, seed) {
log.debug(`background.createNewVaultAndRestore`)
return new Promise((resolve, reject) => {
background.createNewVaultAndRestore(password, seed, err => {
background.clearSeedWordCache((err) => {
if (err) {
return reject(err)
}
background.createNewVaultAndRestore(password, seed, (err) => {
if (err) {
return reject(err)
}
@ -421,6 +426,7 @@ function createNewVaultAndRestore (password, seed) {
resolve()
})
})
})
.then(() => dispatch(actions.unMarkPasswordForgotten()))
.then(() => {
dispatch(actions.showAccountsPage())

Loading…
Cancel
Save