Scheduling infrastructure for absolutely everyone.
Add videoCallData to evt on new attendee (#6673)
Joe Au-Yeung00bff598efb0
diff --git a/packages/features/bookings/lib/handleNewBooking.ts b/packages/features/bookings/lib/handleNewBooking.tsindex 0a2d292d3dd..fa389846ece 100644--- a/packages/features/bookings/lib/handleNewBooking.ts+++ b/packages/features/bookings/lib/handleNewBooking.ts@@ -593,6 +593,16 @@ async function handler(req: NextApiRequest & { userId?: number | undefined }) {throw new HttpError({ statusCode: 409, message: "Already signed up for time slot" });}+ const videoCallReference = booking.references.find((reference) => reference.type.includes("_video"));++ if (videoCallReference) {+ evt.videoCallData = {+ type: videoCallReference.type,+ id: videoCallReference.meetingId,+ password: videoCallReference?.meetingPassword,+ url: videoCallReference.meetingUrl,+ };+ }await prisma.booking.update({where: {uid: reqBody.bookingUid,