From f4c66b2c8c243935bf25f689b16afaa5d6345f1b Mon Sep 17 00:00:00 2001 From: Oscar Hinton Date: Fri, 19 Nov 2021 16:48:42 +0100 Subject: [PATCH] Add support for hiding input on lock screen if using key connector (#560) --- angular/src/components/lock.component.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/angular/src/components/lock.component.ts b/angular/src/components/lock.component.ts index 34f34f1134..bd11e9acce 100644 --- a/angular/src/components/lock.component.ts +++ b/angular/src/components/lock.component.ts @@ -37,6 +37,7 @@ export class LockComponent implements OnInit { supportsBiometric: boolean; biometricLock: boolean; biometricText: string; + hideInput: boolean; protected successRoute: string = 'vault'; protected onSuccessfulSubmit: () => void; @@ -60,9 +61,11 @@ export class LockComponent implements OnInit { (await this.cryptoService.hasKeyStored('biometric') || !this.platformUtilsService.supportsSecureStorage()); this.biometricText = await this.storageService.get(ConstantsService.biometricText); this.email = await this.userService.getEmail(); + const usesKeyConnector = await this.keyConnectorService.getUsesKeyConnector(); + this.hideInput = usesKeyConnector && !this.pinLock; // Users with key connector and without biometric or pin has no MP to unlock using - if (await this.keyConnectorService.getUsesKeyConnector() && !(this.biometricLock || this.pinLock)) { + if (usesKeyConnector && !(this.biometricLock || this.pinLock)) { await this.vaultTimeoutService.logOut(); }