Module: SmtpDeliverable

Extended by:
ActiveSupport::Concern
Defined in:
app/mailers/concerns/smtp_deliverable.rb

Overview

Include in any ActionMailer subclass to wire up SMTP delivery from ThecoreSettings at send time (no application restart needed).

class MyMailer < ApplicationMailer
  include SmtpDeliverable
  ...
end

The concern registers an after_action that overwrites the delivery method with settings read from ThecoreSettings (ns: :smtp). If smtp.address is blank the mailer falls back to whatever delivery_method is configured in the Rails environment (e.g. :test or :letter_opener in development).