1
0
mirror of https://github.com/bitwarden/browser.git synced 2025-12-05 09:14:28 +01:00

Handle delayed availability of biometric unlock

This commit is contained in:
Dubzer 2025-11-22 16:13:34 +03:00
parent 13940a74ae
commit 2f701a601b
No known key found for this signature in database

View File

@ -205,9 +205,18 @@ export class LockComponent implements OnInit, OnDestroy {
.pipe(
mergeMap(async () => {
if (this.activeAccount?.id != null) {
const biometricWasEnabled = this.unlockOptions?.biometrics.enabled;
this.unlockOptions = await firstValueFrom(
this.lockComponentService.getAvailableUnlockOptions$(this.activeAccount.id),
);
if (!biometricWasEnabled && this.unlockOptions?.biometrics.enabled) {
this.setDefaultActiveUnlockOption(this.unlockOptions);
if (this.activeUnlockOption === UnlockOption.Biometrics) {
await this.handleBiometricsUnlockEnabled();
}
}
}
}),
takeUntil(this.destroy$),