fix: don't send reassingment email to attendee for past events (#18173)

Co-authored-by: CarinaWolli <[email protected]>
This commit is contained in:
Carina WollendorferandCarinaWolli authored and GitHub committed 2024-12-13 19:02:54 +00:00
1 parent 18a0eb9736
commit 376961f30d
2 files changed
+2 -2

No files matched your search

@@ -346,7 +346,7 @@ export const roundRobinManualReassignment = async ({
}
if (hasOrganizerChanged) {
if (emailsEnabled) {
if (emailsEnabled && dayjs(evt.startTime).isAfter(dayjs())) {
// send email with event updates to attendees
await sendRoundRobinUpdatedEmailsAndSMS({
calEvent: evtWithoutCancellationReason,
@@ -396,7 +396,7 @@ export const roundRobinReassignment = async ({
// Handle changing workflows with organizer
if (hasOrganizerChanged) {
if (emailsEnabled) {
if (emailsEnabled && dayjs(evt.startTime).isAfter(dayjs())) {
// send email with event updates to attendees
await sendRoundRobinUpdatedEmailsAndSMS({
calEvent: evtWithoutCancellationReason,