- commit
- 5668c417df3c826954f8a7f8759ec2505cdd1bd1
- parent
- 19e7f818259a1b1e4810d465fc72426fcaa29200
- Author
- Tobias Bengfort <tobias.bengfort@posteo.de>
- Date
- 2024-07-31 17:21
mail: set Auto-Submitted header
Diffstat
| M | mfa/mail.py | 7 | ++++++- |
1 files changed, 6 insertions, 1 deletions
diff --git a/mfa/mail.py b/mfa/mail.py
@@ -30,7 +30,12 @@ def send_mail(user, method): 30 30 except TemplateDoesNotExist: 31 31 return 0 32 3233 -1 message = EmailMultiAlternatives(subject, body, to=[user_email])-1 33 message = EmailMultiAlternatives( -1 34 subject, -1 35 body, -1 36 to=[user_email], -1 37 headers={'Auto-Submitted': 'auto-generated'}, -1 38 ) 34 39 35 40 try: 36 41 html_body = loader.render_to_string(HTML_TEMPLATE, context)