fix: host entry not created when user added to team in org (#17927)
Co-authored-by: Alex van Andel <me@alexvanandel.com>
This commit is contained in:
1 parent
a5ba2682f6
commit
c524a3c1ef
1 file changed
+5
@@ -1,3 +1,4 @@
|
||||
import { updateNewTeamMemberEventTypes } from "@calcom/lib/server/queries";
|
||||
import { isOrganisationAdmin } from "@calcom/lib/server/queries/organisations";
|
||||
import { prisma } from "@calcom/prisma";
|
||||
import type { Prisma } from "@calcom/prisma/client";
|
||||
@@ -76,6 +77,10 @@ export const addMembersToTeams = async ({ user, input }: AddBulkToTeamProps) =>
|
||||
data: membershipData,
|
||||
});
|
||||
|
||||
membershipData.forEach(async ({ userId, teamId }) => {
|
||||
await updateNewTeamMemberEventTypes(userId, teamId);
|
||||
});
|
||||
|
||||
return {
|
||||
success: true,
|
||||
invitedTotalUsers: input.userIds.length,
|
||||
|
||||
Reference in new issue
Block a user