1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-10 21:33:27 +00:00

[PM-12628] Fix cli showing locked status when using session and check (#17515)

* Fix cli showing locked status when using session and check

* Cleanup
This commit is contained in:
Bernd Schoolmann
2025-12-02 14:39:18 +01:00
committed by GitHub
parent 2510844293
commit 2e8faa9994

View File

@@ -277,6 +277,11 @@ export class Program extends BaseProgram {
})
.option("--check", "Check lock status.", async () => {
await this.exitIfNotAuthed();
const userId = (await firstValueFrom(this.serviceContainer.accountService.activeAccount$))
?.id;
await this.serviceContainer.userAutoUnlockKeyService.setUserKeyInMemoryIfAutoUserKeySet(
userId,
);
const authStatus = await this.serviceContainer.authService.getAuthStatus();
if (authStatus === AuthenticationStatus.Unlocked) {