Skip to content

fix(notifications): don't fail if ccEmails missing from data

Ben Whitmore requested to merge mail-fix-20240214 into main

I noticed several errors in the kotahidev logs like this:

image

The sendEmailNotification function expects data.ccEmails to be supplied if the "CC editors" option is enabled on the email template. But most places in code that sendEmailNotification is used don't supply data.ccEmails, so we get an error and the email doesn't get sent.

I've made the code lenient so that it won't fail if ccEmails isn't supplied.

Merge request reports