Module: ThecoreBackgroundJobs

Defined in:
lib/thecore_background_jobs.rb,
lib/thecore_background_jobs/engine.rb,
lib/thecore_background_jobs/version.rb

Defined Under Namespace

Classes: Engine

Constant Summary collapse

VERSION =
"#{`git describe --tags $(git rev-list --tags --max-count=1)`.chomp}"

Class Method Summary collapse

Class Method Details

.email_setupObject

Your code goes here…



9
10
11
12
13
14
15
16
# File 'lib/thecore_background_jobs.rb', line 9

def self.email_setup
  delivery_options = { domain: Settings.ns(:smtp).domain, address: Settings.ns(:smtp).address, port: Settings.ns(:smtp).port.to_i, enable_starttls_auto: (Settings.ns(:smtp).enable_starttls_auto == "true")}
  # Other Options
  delivery_options.merge!({user_name: Settings.ns(:smtp).user_name}) unless Settings.ns(:smtp).user_name.blank?
  delivery_options.merge!({password: Settings.ns(:smtp).password}) unless Settings.ns(:smtp).password.blank?
  delivery_options.merge!({authentication: Settings.ns(:smtp).authentication}) unless Settings.ns(:smtp).authentication.blank? 
  delivery_options
end