mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-10-15 09:35:37 +00:00
feat: updated to enum ActionProjectType
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import { ProjectMembershipRole, ProjectOperationType } from "@app/db/schemas";
|
||||
import { ActionProjectType, ProjectMembershipRole } from "@app/db/schemas";
|
||||
import { TPermissionServiceFactory } from "@app/ee/services/permission/permission-service";
|
||||
import { ForbiddenRequestError, NotFoundError } from "@app/lib/errors";
|
||||
|
||||
@@ -37,7 +37,7 @@ export const secretBlindIndexServiceFactory = ({
|
||||
projectId,
|
||||
actorAuthMethod,
|
||||
actorOrgId,
|
||||
projectOperationType: ProjectOperationType.SecretManager
|
||||
projectOperationType: ActionProjectType.SecretManager
|
||||
});
|
||||
|
||||
const secretCount = await secretBlindIndexDAL.countOfSecretsWithNullSecretBlindIndex(projectId);
|
||||
@@ -57,7 +57,7 @@ export const secretBlindIndexServiceFactory = ({
|
||||
projectId,
|
||||
actorAuthMethod,
|
||||
actorOrgId,
|
||||
projectOperationType: ProjectOperationType.SecretManager
|
||||
projectOperationType: ActionProjectType.SecretManager
|
||||
});
|
||||
if (!hasRole(ProjectMembershipRole.Admin)) {
|
||||
throw new ForbiddenRequestError({ message: "Insufficient privileges, user must be admin" });
|
||||
@@ -81,7 +81,7 @@ export const secretBlindIndexServiceFactory = ({
|
||||
projectId,
|
||||
actorAuthMethod,
|
||||
actorOrgId,
|
||||
projectOperationType: ProjectOperationType.SecretManager
|
||||
projectOperationType: ActionProjectType.SecretManager
|
||||
});
|
||||
if (!hasRole(ProjectMembershipRole.Admin)) {
|
||||
throw new ForbiddenRequestError({ message: "Insufficient privileges, user must be admin" });
|
||||
|
||||
Reference in New Issue
Block a user