fix: webhooks for managed event types (#10958)
Co-authored-by: CarinaWolli <[email protected]> Co-authored-by: Omar López <[email protected]>
This commit is contained in:
8 files changed
+36
-14
No files matched your search
@@ -248,9 +248,12 @@ export const requestRescheduleHandler = async ({ ctx, input }: RequestReschedule
|
||||
parentId: bookingToReschedule?.eventType?.parentId ?? null,
|
||||
},
|
||||
});
|
||||
|
||||
const triggerForUser = !teamId || (teamId && bookingToReschedule.eventType?.parentId);
|
||||
|
||||
// Send Webhook call if hooked to BOOKING.CANCELLED
|
||||
const subscriberOptions = {
|
||||
userId: bookingToReschedule.userId,
|
||||
userId: triggerForUser ? bookingToReschedule.userId : null,
|
||||
eventTypeId: bookingToReschedule.eventTypeId as number,
|
||||
triggerEvent: eventTrigger,
|
||||
teamId,
|
||||
|
||||
Reference in new issue
Block a user