Sha256: be4c69f10afb8e5542cb528d3552baa6b815513e31d5dc7c4ea10be6b1b3f6fe

Contents?: true

Size: 562 Bytes

Versions: 1

Compression:

Stored size: 562 Bytes

Contents

require 'mail'
module ActionTexter
  module Provider
    module Mail
      class Delivery
      
        def initialize(settings = {})
          @charset = settings[:charset]
        end

        def deliver(message)

          mail = ::Mail.new do |mail|
            from message.from
            to message.to
            cc message.cc 
            subject message.subject
            body message.body.to_s

            self.charset = @charset
          end

          #LOGGER.info(mail.body)

          mail.deliver!

        end
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
action-texter-0.2.0.pre lib/action_texter/provider/mail/delivery.rb