mirror of
https://github.com/bitwarden/browser
synced 2025-12-12 14:23:32 +00:00
[SG-659] Classic 2019 plans no longer generating TOTP codes for Free users (#3509)
* [SG-659] Fixed TOTP code visibility for users with classic plans. * [SG-659] Refactored condition. * [SG-659] Ran prettier * [SG-659] Simplified expression.
This commit is contained in:
committed by
GitHub
parent
a4ef63da37
commit
acf332b689
@@ -50,6 +50,7 @@ export class ViewComponent implements OnDestroy, OnInit {
|
||||
showCardNumber: boolean;
|
||||
showCardCode: boolean;
|
||||
canAccessPremium: boolean;
|
||||
showPremiumRequiredTotp: boolean;
|
||||
totpCode: string;
|
||||
totpCodeFormatted: string;
|
||||
totpDash: number;
|
||||
@@ -108,6 +109,8 @@ export class ViewComponent implements OnDestroy, OnInit {
|
||||
const cipher = await this.cipherService.get(this.cipherId);
|
||||
this.cipher = await cipher.decrypt();
|
||||
this.canAccessPremium = await this.stateService.getCanAccessPremium();
|
||||
this.showPremiumRequiredTotp =
|
||||
this.cipher.login.totp && !this.canAccessPremium && !this.cipher.organizationUseTotp;
|
||||
|
||||
if (
|
||||
this.cipher.type === CipherType.Login &&
|
||||
|
||||
Reference in New Issue
Block a user