Skip to content

Commit 385f5fa

Browse files
remove check for organization
1 parent a02977f commit 385f5fa

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

apps/web/src/app/vault/components/vault-items/vault-cipher-row.component.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -150,9 +150,7 @@ export class VaultCipherRowComponent<C extends CipherViewLike> implements OnInit
150150
}
151151

152152
return (
153-
!CipherViewLikeUtils.isArchived(this.cipher) &&
154-
!CipherViewLikeUtils.isDeleted(this.cipher) &&
155-
!this.cipher.organizationId
153+
!CipherViewLikeUtils.isArchived(this.cipher) && !CipherViewLikeUtils.isDeleted(this.cipher)
156154
);
157155
}
158156

libs/angular/src/vault/vault-filter/components/vault-filter.component.ts

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
// FIXME: Update this file to be type safe and remove this and next line
22
// @ts-strict-ignore
33
import { Directive, EventEmitter, Input, OnInit, Output } from "@angular/core";
4-
import { firstValueFrom, Observable } from "rxjs";
4+
import { firstValueFrom, map, Observable } from "rxjs";
55

66
// This import has been flagged as unallowed for this class. It may be involved in a circular dependency loop.
77
// eslint-disable-next-line no-restricted-imports
@@ -91,11 +91,13 @@ export class VaultFilterComponent implements OnInit {
9191
const userCanArchive = await firstValueFrom(
9292
this.cipherArchiveService.userCanArchive$(this.activeUserId),
9393
);
94-
const showArchiveVault = await firstValueFrom(
95-
this.cipherArchiveService.showArchiveVault$(this.activeUserId),
94+
const hasArchiveItems = await firstValueFrom(
95+
this.cipherArchiveService
96+
.archivedCiphers$(this.activeUserId)
97+
.pipe(map((ciphers) => ciphers.length > 0)),
9698
);
9799

98-
this.showArchiveVaultFilter = userCanArchive || showArchiveVault;
100+
this.showArchiveVaultFilter = userCanArchive || hasArchiveItems;
99101
this.isLoaded = true;
100102
}
101103

0 commit comments

Comments
 (0)