FEATURE: Add `before_email_send` event
Plugins can use it to customize the message (e.g. add header) before the email is sent.
This commit is contained in:
parent
5143309014
commit
2da6faf281
|
@ -209,6 +209,8 @@ module Email
|
|||
|
||||
email_log.message_id = @message.message_id
|
||||
|
||||
DiscourseEvent.trigger(:before_email_send, @message, @email_type)
|
||||
|
||||
begin
|
||||
@message.deliver_now
|
||||
rescue *SMTP_CLIENT_ERRORS => e
|
||||
|
|
Loading…
Reference in New Issue