Module: ThemesForRails::ActionMailer

Extended by:
ActiveSupport::Concern
Defined in:
lib/themes_for_rails/action_mailer.rb

Instance Method Summary collapse

Instance Method Details

#mail_with_theme(headers = {}, &block) ⇒ Object



13
14
15
16
17
18
# File 'lib/themes_for_rails/action_mailer.rb', line 13

def mail_with_theme(headers = {}, &block)
  theme_opts = headers[:theme] || self.class.default[:theme]
  theme(theme_opts) if theme_opts

  mail_without_theme(headers, &block)
end