Skip to content

Commit be8fe26

Browse files
committed
Set the From: header for copied mail to the test address, so that
test messages don't look so much like spam. - Legacy-Id: 1156
1 parent a98366f commit be8fe26

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

ietf/utils/mail.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,9 @@ def copy_email(msg, to, toUser=False):
7272
Send a copy of the given email message to the given recipient.
7373
'''
7474
add_headers(msg)
75+
# Overwrite the From: header, so that the copy from a development or
76+
# test server doesn't look like spam.
77+
msg['From'] = settings.DEFAULT_FROM_EMAIL
7578
new = MIMEMultipart()
7679
# get info for first part.
7780
# Mode: if it's production, then "copy of a message", otherwise

0 commit comments

Comments
 (0)