Stops users who are not in getting the "Requires confirmation" email (#3084)

* Update Email

* Remove console.debug

* Remove redundant assignment

Co-authored-by: Omar López <[email protected]>

* Update apps/web/pages/api/book/confirm.ts

* Fix E2E test

Co-authored-by: Peer Richelsen <[email protected]>
Co-authored-by: Omar López <[email protected]>
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
This commit is contained in:
authored and GitHub committed 2022-06-17 09:02:29 +00:00
1 parent 2e79446667
commit d44c8f7912
6 files changed
+7 -3

No files matched your search

+2
View File
@@ -105,6 +105,7 @@ async function patchHandler(req: NextApiRequest) {
eventType: {
select: {
recurringEvent: true,
requiresConfirmation: true,
},
},
location: true,
@@ -176,6 +177,7 @@ async function patchHandler(req: NextApiRequest) {
location: booking.location ?? "",
uid: booking.uid,
destinationCalendar: booking?.destinationCalendar || currentUser.destinationCalendar,
requiresConfirmation: booking?.eventType?.requiresConfirmation ?? false,
};
const recurringEvent = parseRecurringEvent(booking.eventType?.recurringEvent);
+1
View File
@@ -402,6 +402,7 @@ async function handler(req: NextApiRequest) {
/** For team events & dynamic collective events, we will need to handle each member destinationCalendar eventually */
destinationCalendar: eventType.destinationCalendar || organizerUser.destinationCalendar,
hideCalendarNotes: eventType.hideCalendarNotes,
requiresConfirmation: eventType.requiresConfirmation ?? false,
};
if (eventType.schedulingType === SchedulingType.COLLECTIVE) {