Commit d8135392d99d21d8a3365b9ceffe2c336aaee6e5

Authored by Stephen Crosby
2 parents f800d8e6 259b96d8
Exists in master and in 1 other branch production

Merge pull request #712 from bdehamer/optional-errbit-email-from

Allow app to start w/o ERRBIT_EMAIL_FROM
Showing 1 changed file with 2 additions and 1 deletions   Show diff stats
config/initializers/_load_config.rb
... ... @@ -37,7 +37,8 @@ unless defined?(Errbit::Config)
37 37 :authentication => :plain,
38 38 :user_name => ENV['SMTP_USERNAME'] || ENV['SENDGRID_USERNAME'],
39 39 :password => ENV['SMTP_PASSWORD'] || ENV['SENDGRID_PASSWORD'],
40   - :domain => ENV['SMTP_DOMAIN'] || ENV['SENDGRID_DOMAIN'] || ENV['ERRBIT_EMAIL_FROM'].split('@').last
  40 + :domain => ENV['SMTP_DOMAIN'] || ENV['SENDGRID_DOMAIN'] ||
  41 + (ENV['ERRBIT_EMAIL_FROM'] ? ENV['ERRBIT_EMAIL_FROM'].split('@').last : nil)
41 42 }
42 43 end
43 44  
... ...