mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-10-11 14:28:56 +00:00
fix: check for recipients to send project access email
This commit is contained in:
@@ -198,6 +198,7 @@ export const orgAdminServiceFactory = ({
|
|||||||
)
|
)
|
||||||
.map((el) => el.user.email!);
|
.map((el) => el.user.email!);
|
||||||
|
|
||||||
|
if (filteredProjectMembers.length) {
|
||||||
await smtpService.sendMail({
|
await smtpService.sendMail({
|
||||||
template: SmtpTemplates.OrgAdminProjectDirectAccess,
|
template: SmtpTemplates.OrgAdminProjectDirectAccess,
|
||||||
recipients: filteredProjectMembers,
|
recipients: filteredProjectMembers,
|
||||||
@@ -207,6 +208,7 @@ export const orgAdminServiceFactory = ({
|
|||||||
email: projectMembers.find((el) => el.userId === actorId)?.user?.username
|
email: projectMembers.find((el) => el.userId === actorId)?.user?.username
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
}
|
||||||
return { isExistingMember: false, membership: updatedMembership };
|
return { isExistingMember: false, membership: updatedMembership };
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user