Class: MnoEnterprise::MailAdapters::SmtpAdapter

Inherits:
Adapter
  • Object
show all
Defined in:
lib/mno_enterprise/mail_adapters/smtp_adapter.rb

Overview

SMTP Adapter for MnoEnterprise::MailClient

Class Method Summary collapse

Methods inherited from Adapter

base_deliveries, test?

Class Method Details

.clientSmtpClient

Return a smtp client configured with the SMTP settings

Returns:



8
9
10
# File 'lib/mno_enterprise/mail_adapters/smtp_adapter.rb', line 8

def client
  @client = MnoEnterprise::SmtpClient.send :new
end

.deliver(template, from, to, vars = {}, opts = {}) ⇒ Object

Send a template



14
15
16
# File 'lib/mno_enterprise/mail_adapters/smtp_adapter.rb', line 14

def deliver(template, from, to, vars={}, opts={})
  client.deliver(template, from, to, vars, opts).deliver
end