Skip to content

Infisical is the open-source platform for securing secrets, certificates, access, and AI Agents.

Address greptile comments

Carlos Monastyrskia458086c7234
diff --git a/frontend/src/pages/cert-manager/ApplicationDetailsByIDPage/components/AddApplicationMemberModal.tsx b/frontend/src/pages/cert-manager/ApplicationDetailsByIDPage/components/AddApplicationMemberModal.tsx
index ed30f5ad18..53c781269d 100644
--- a/frontend/src/pages/cert-manager/ApplicationDetailsByIDPage/components/AddApplicationMemberModal.tsx
+++ b/frontend/src/pages/cert-manager/ApplicationDetailsByIDPage/components/AddApplicationMemberModal.tsx
@@ -101,7 +101,7 @@ export const AddApplicationMemberModal = ({
const usersQuery = useGetWorkspaceUsers(projectId);
const identitiesQuery = useListProjectIdentityMemberships({
- projectId: "",
+ projectId,
projectType: ProjectType.CertificateManager,
limit: 1000
});
@@ -173,12 +173,21 @@ export const AddApplicationMemberModal = ({
if (selectedUsers.length === 0) return;
const userIds = selectedUsers.map((u) => u.value);
- await addUserMembers.mutateAsync({
+ const result = await addUserMembers.mutateAsync({
applicationId,
userIds,
emails: [],
role
});
+
+ if (result.unresolved.length > 0) {
+ const labelById = new Map(selectedUsers.map((u) => [u.value, u.label]));
+ const names = result.unresolved.map((id) => labelById.get(id) ?? id);
+ createNotification({
+ type: "warning",
+ text: `Couldn't add ${names.length === 1 ? "this user" : "these users"}: ${names.join(", ")}. Grant them access from the Access Control page and try again.`
+ });
+ }
};
const submitIdentities = async () => {