提交 c6ebe440 编写于 作者: R Ruben Davila

Use #parts instead of #part to read all the parts of the Message.

Looks like I was accidentally using #part which was adding an extra
empty Mime section
上级 6c624821
......@@ -5,8 +5,8 @@ class EmailTemplateInterceptor
def self.delivering_email(message)
# Remove HTML part if HTML emails are disabled.
unless current_application_settings.html_emails_enabled
message.part.delete_if do |part|
part.content_type.try(:start_with?, 'text/html')
message.parts.delete_if do |part|
part.content_type.start_with?('text/html')
end
end
end
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册