mirror of
https://github.com/bitwarden/browser
synced 2026-02-18 18:33:50 +00:00
[PM-28648] Handle delayed availability of biometric unlock (#17603)
* Handle delayed availability of biometric unlock * Fix linting --------- Co-authored-by: Bernd Schoolmann <mail@quexten.com>
This commit is contained in:
@@ -217,12 +217,20 @@ export class LockComponent implements OnInit, OnDestroy {
|
||||
.pipe(
|
||||
mergeMap(async () => {
|
||||
if (this.activeAccount?.id != null) {
|
||||
const prevBiometricsEnabled = this.unlockOptions?.biometrics.enabled;
|
||||
|
||||
this.unlockOptions = await firstValueFrom(
|
||||
this.lockComponentService.getAvailableUnlockOptions$(this.activeAccount.id),
|
||||
);
|
||||
|
||||
if (this.activeUnlockOption == null) {
|
||||
this.loading = false;
|
||||
await this.setDefaultActiveUnlockOption(this.unlockOptions);
|
||||
} else if (!prevBiometricsEnabled && this.unlockOptions?.biometrics.enabled) {
|
||||
await this.setDefaultActiveUnlockOption(this.unlockOptions);
|
||||
if (this.activeUnlockOption === UnlockOption.Biometrics) {
|
||||
await this.handleBiometricsUnlockEnabled();
|
||||
}
|
||||
}
|
||||
}
|
||||
}),
|
||||
|
||||
Reference in New Issue
Block a user