Skip to content

Commit

Permalink
Add preproduction and production mailer configurations
Browse files Browse the repository at this point in the history
  • Loading branch information
Senen committed Dec 20, 2017
1 parent 7d2fee0 commit 96be6df
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
2 changes: 1 addition & 1 deletion app/views/user_mailer/infringement_email.html.erb
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<%= t('mailer.infringement_email.link_html', link: @email.link) %>
<%= t'mailer.infringement_email.link_html', link: @email.link if @email.link.present? %>
<%= @email.description.html_safe %>
<hr />
Expand Down
4 changes: 3 additions & 1 deletion config/environments/preproduction.rb
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,9 @@

# Ignore bad email addresses and do not raise email delivery errors.
# Set this to true and configure the email server for immediate delivery to raise delivery errors.
# config.action_mailer.raise_delivery_errors = false
config.action_mailer.raise_delivery_errors = true
config.action_mailer.default_url_options = { host: Rails.application.secrets.server_name }
config.action_mailer.asset_host = "https://#{Rails.application.secrets.server_name}"

# Enable locale fallbacks for I18n (makes lookups for any locale fall back to
# the I18n.default_locale when a translation cannot be found).
Expand Down
4 changes: 3 additions & 1 deletion config/environments/production.rb
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,9 @@

# Ignore bad email addresses and do not raise email delivery errors.
# Set this to true and configure the email server for immediate delivery to raise delivery errors.
# config.action_mailer.raise_delivery_errors = false
config.action_mailer.raise_delivery_errors = true
config.action_mailer.default_url_options = { host: Rails.application.secrets.server_name }
config.action_mailer.asset_host = "https://#{Rails.application.secrets.server_name}"

# Enable locale fallbacks for I18n (makes lookups for any locale fall back to
# the I18n.default_locale when a translation cannot be found).
Expand Down

0 comments on commit 96be6df

Please sign in to comment.