1
0
mirror of https://github.com/bitwarden/desktop.git synced 2024-11-28 12:35:40 +01:00

Fix logging out of all accounts instead of one (#1231)

When logOut is triggered and the userId is not provided. Retrieve currentUserId
This commit is contained in:
Daniel James Smith 2022-01-13 15:43:00 +01:00 committed by GitHub
parent 7818ffc2fb
commit abede3e5af
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -434,6 +434,10 @@ export class AppComponent implements OnInit {
}
private async logOut(expired: boolean, userId?: string) {
if (!userId) {
userId = await this.stateService.getUserId();
}
await Promise.all([
this.eventService.uploadEvents(userId),
this.syncService.setLastSync(new Date(0), userId),