From 0d035c5a09148666998eb8039d67acfadd19adf9 Mon Sep 17 00:00:00 2001 From: Thomas Rittson <31796059+eliykat@users.noreply.github.com> Date: Sat, 2 Dec 2023 01:45:52 +1000 Subject: [PATCH] [AC-1873] Only assign user in the front-end if using Flexible Collections (#7051) * Only assign user in the front-end if using Flexible Collections * Fix prettier --- .../collection-dialog/collection-dialog.component.ts | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/apps/web/src/app/vault/components/collection-dialog/collection-dialog.component.ts b/apps/web/src/app/vault/components/collection-dialog/collection-dialog.component.ts index 5c220672eaec..92022fc2003c 100644 --- a/apps/web/src/app/vault/components/collection-dialog/collection-dialog.component.ts +++ b/apps/web/src/app/vault/components/collection-dialog/collection-dialog.component.ts @@ -204,14 +204,12 @@ export class CollectionDialogComponent implements OnInit, OnDestroy { const currentOrgUserId = users.data.find((u) => u.userId === this.organization?.userId) ?.id; const initialSelection: AccessItemValue[] = - currentOrgUserId !== undefined + currentOrgUserId !== undefined && flexibleCollections ? [ { id: currentOrgUserId, type: AccessItemType.Member, - permission: flexibleCollections - ? CollectionPermission.Manage - : CollectionPermission.Edit, + permission: CollectionPermission.Manage, }, ] : [];