classic-ui/modules/account/store/actions/checkRecoveryKey.js
2022-10-13 15:50:29 +02:00

9 lines
265 B
JavaScript

export function checkRecoveryKey({ getters, dispatch }) {
const { encrypt: address } = getters.accounts
const recoveryKey = this.$sessionStorage.getItem(address)
if (!recoveryKey && !getters.encryptedPrivateKey) {
dispatch('removeAccount')
}
}