1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-06 00:13:28 +00:00

clear orgId when switching to a personal vault (#16396)

This commit is contained in:
Jordan Aasen
2025-09-16 11:52:46 -07:00
committed by GitHub
parent 4711e51de3
commit 3a6088c187

View File

@@ -926,17 +926,22 @@ export class VaultV2Component<C extends CipherViewLike>
}
} else if (this.activeFilter.selectedOrganizationId) {
this.addOrganizationId = this.activeFilter.selectedOrganizationId;
} else {
// clear out organizationId when the user switches to a personal vault filter
this.addOrganizationId = null;
}
if (this.activeFilter.selectedFolderId && this.activeFilter.selectedFolder) {
this.folderId = this.activeFilter.selectedFolderId;
}
if (this.addOrganizationId && this.config) {
this.config.initialValues = {
...this.config.initialValues,
organizationId: this.addOrganizationId as OrganizationId,
};
if (this.config == null) {
return;
}
this.config.initialValues = {
...this.config.initialValues,
organizationId: this.addOrganizationId as OrganizationId,
};
}
private async canNavigateAway(action: string, cipher?: CipherView) {