enonic / xp

Enonic XP
https://enonic.com
GNU General Public License v3.0
200 stars 34 forks source link

Default email sender is not working #10404

Closed alansemenov closed 5 months ago

alansemenov commented 7 months ago

If defaultFromEmail is set in the XP mail configuration, it should be used in outgoing emails when it's not explicitly specified.

Examples (assume that defaultFromEmail is set to noreply@enonic.com): 1) If an email is sent with Some Name<email@domain.com> as a sender, use that as is. 2) If an email is sent with email@domain.com as a sender, use that as is. 3) If an email is sent with Some Name<> as a sender, substitute value from defaultFromEmail so that it's sent from Some Name<noreply@enonic.com>. 4) If an email is sent with <> as a sender or sender not specified, use value from defaultFromEmail so that it's sent from noreply@enonic.com.

Throw an error if the value from defaultFromEmail is required (like in cases 3 and 4 above) but not configured.