parent
2b51cd9c8d
commit
2430784142
|
@ -189,17 +189,20 @@ export default class EventManager {
|
|||
}
|
||||
|
||||
const isDedicated = evt.location ? isDedicatedIntegration(evt.location) : null;
|
||||
// First, create all calendar events. If this is a dedicated integration event, don't send a mail right here.
|
||||
const results: Array<EventResult> = await this.updateAllCalendarEvents(evt, booking);
|
||||
const results: Array<EventResult> = [];
|
||||
// If and only if event type is a dedicated meeting, update the dedicated video meeting.
|
||||
if (isDedicated) {
|
||||
const result = await this.updateVideoEvent(evt, booking);
|
||||
if (result.updatedEvent) {
|
||||
evt.videoCallData = result.updatedEvent;
|
||||
evt.location = result.updatedEvent.url;
|
||||
}
|
||||
results.push(result);
|
||||
}
|
||||
|
||||
// Update all calendar events.
|
||||
results.push(...(await this.updateAllCalendarEvents(evt, booking)));
|
||||
|
||||
// Now we can delete the old booking and its references.
|
||||
const bookingReferenceDeletes = prisma.bookingReference.deleteMany({
|
||||
where: {
|
||||
|
|
Loading…
Reference in New Issue