Class: LetterThief::EmailMessage
- Inherits:
-
ApplicationRecord
- Object
- ActiveRecord::Base
- ApplicationRecord
- LetterThief::EmailMessage
- Defined in:
- app/models/letter_thief/email_message.rb
Instance Method Summary collapse
Instance Method Details
#multipart? ⇒ Boolean
26 27 28 |
# File 'app/models/letter_thief/email_message.rb', line 26 def multipart? body_text.present? && body_html.present? end |
#rich? ⇒ Boolean
22 23 24 |
# File 'app/models/letter_thief/email_message.rb', line 22 def rich? type == "rich" end |
#type ⇒ Object
18 19 20 |
# File 'app/models/letter_thief/email_message.rb', line 18 def type /html/.match?(content_type) ? "rich" : "plain" end |