Skip to content

Commit

Permalink
feat: fixed wrong permission type in bulk api op
Browse files Browse the repository at this point in the history
  • Loading branch information
akhilmhdh committed Apr 1, 2024
1 parent 42cd98d commit 9903f7c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions backend/src/services/secret/secret-service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -655,7 +655,7 @@ export const secretServiceFactory = ({
actorOrgId
);
ForbiddenError.from(permission).throwUnlessCan(
ProjectPermissionActions.Create,
ProjectPermissionActions.Edit,
subject(ProjectPermissionSub.Secrets, { environment, secretPath: path })
);

Expand Down Expand Up @@ -741,7 +741,7 @@ export const secretServiceFactory = ({
actorOrgId
);
ForbiddenError.from(permission).throwUnlessCan(
ProjectPermissionActions.Create,
ProjectPermissionActions.Delete,
subject(ProjectPermissionSub.Secrets, { environment, secretPath: path })
);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -416,7 +416,7 @@ export const ActionBar = ({
{Object.keys(selectedSecrets).length} Selected
</div>
<ProjectPermissionCan
I={ProjectPermissionActions.Edit}
I={ProjectPermissionActions.Delete}
a={subject(ProjectPermissionSub.Secrets, { environment, secretPath })}
renderTooltip
allowedLabel="Delete"
Expand Down

0 comments on commit 9903f7c

Please sign in to comment.