fix: hide protections paragraph when no account or passcode exist

This commit is contained in:
Baptiste Grob
2021-02-15 16:28:36 +01:00
parent 523feff6c8
commit aa34bfc0c6
2 changed files with 5 additions and 1 deletions

View File

@@ -189,6 +189,10 @@ class AccountMenuCtrl extends PureViewCtrl<unknown, AccountMenuState> {
});
}
hasProtections() {
return this.application.hasAccount() || this.application.hasPasscode();
}
private getProtectionsDisabledUntil(): string | null {
const protectionExpiry = this.application.getProtectionSessionExpiryDate();
const now = new Date();