module Rodauth::Rails::Feature::Email

Public Class Methods

included(feature) click to toggle source
# File lib/rodauth/rails/feature/email.rb, line 5
def self.included(feature)
  feature.depends :email_base
end

Private Instance Methods

create_email_to(to, subject, body) click to toggle source

Create emails with ActionMailer which uses configured delivery method.

# File lib/rodauth/rails/feature/email.rb, line 12
def create_email_to(to, subject, body)
  Mailer.create_email(to: to, from: email_from, subject: "#{email_subject_prefix}#{subject}", body: body)
end
send_email(email) click to toggle source

Delivers the given email.

# File lib/rodauth/rails/feature/email.rb, line 17
def send_email(email)
  email.deliver_now
end