Skip to content

Commit

Permalink
do not add mime-version header if already present (#1302)
Browse files Browse the repository at this point in the history
  • Loading branch information
nguyenkims authored Sep 22, 2022
1 parent b5aff49 commit 72a130e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion app/email_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -319,7 +319,8 @@ def send_email(
date_header = formatdate()
msg[headers.DATE] = date_header

msg[headers.MIME_VERSION] = "1.0"
if headers.MIME_VERSION not in msg:
msg[headers.MIME_VERSION] = "1.0"

if unsubscribe_link:
add_or_replace_header(msg, headers.LIST_UNSUBSCRIBE, f"<{unsubscribe_link}>")
Expand Down

0 comments on commit 72a130e

Please sign in to comment.