Skip to content

Commit

Permalink
Update user mailer from address
Browse files Browse the repository at this point in the history
Send user mail from the blackhole address help reduce the amount of
email we receive to support inboxes.

Fixes #6404
  • Loading branch information
gbp committed May 17, 2024
1 parent 8625991 commit e7c53bf
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions app/mailers/application_mailer.rb
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ def mail_user(user, subject:, **opts)
set_auto_generated_headers

default_opts = {
from: contact_for_user(user),
from: blackhole_email,
to: user.name_and_email,
subject: subject
}
Expand Down Expand Up @@ -82,8 +82,7 @@ def set_auto_generated_headers(_opts = {})
# from transitory bounce messages.
def set_reply_to_headers(opts = {})
default_opts = {
'Return-Path' => blackhole_email,
'Reply-To' => contact_for_user(user)
'Return-Path' => blackhole_email
}
default_opts.merge!(opts)
headers(default_opts)
Expand Down

0 comments on commit e7c53bf

Please sign in to comment.