mirror of
https://github.com/bitwarden/browser
synced 2025-12-19 17:53:39 +00:00
clear user index before account is totally cleaned up
This commit is contained in:
@@ -587,6 +587,7 @@ export class AppComponent implements OnInit, OnDestroy {
|
|||||||
await this.passwordGenerationService.clear(userBeingLoggedOut);
|
await this.passwordGenerationService.clear(userBeingLoggedOut);
|
||||||
await this.vaultTimeoutSettingsService.clear(userBeingLoggedOut);
|
await this.vaultTimeoutSettingsService.clear(userBeingLoggedOut);
|
||||||
await this.biometricStateService.logout(userBeingLoggedOut as UserId);
|
await this.biometricStateService.logout(userBeingLoggedOut as UserId);
|
||||||
|
await this.searchService.clearIndex();
|
||||||
|
|
||||||
await this.stateEventRunnerService.handleEvent("logout", userBeingLoggedOut as UserId);
|
await this.stateEventRunnerService.handleEvent("logout", userBeingLoggedOut as UserId);
|
||||||
|
|
||||||
@@ -609,7 +610,6 @@ export class AppComponent implements OnInit, OnDestroy {
|
|||||||
// This must come last otherwise the logout will prematurely trigger
|
// This must come last otherwise the logout will prematurely trigger
|
||||||
// a process reload before all the state service user data can be cleaned up
|
// a process reload before all the state service user data can be cleaned up
|
||||||
if (userBeingLoggedOut === preLogoutActiveUserId) {
|
if (userBeingLoggedOut === preLogoutActiveUserId) {
|
||||||
await this.searchService.clearIndex();
|
|
||||||
this.authService.logOut(async () => {
|
this.authService.logOut(async () => {
|
||||||
if (expired) {
|
if (expired) {
|
||||||
this.platformUtilsService.showToast(
|
this.platformUtilsService.showToast(
|
||||||
|
|||||||
Reference in New Issue
Block a user