From 3aa777f253a34fe2a2c4634311acc707fd4b6e9d Mon Sep 17 00:00:00 2001 From: vilmibm Date: Fri, 18 Jan 2019 20:55:08 +0000 Subject: [PATCH] tweak emailing to hopefully improve spam situation --- ttadmin/common/mailing.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/ttadmin/common/mailing.py b/ttadmin/common/mailing.py index 0b86671..ccf00b2 100644 --- a/ttadmin/common/mailing.py +++ b/ttadmin/common/mailing.py @@ -7,7 +7,8 @@ from django.conf import settings logger = logging.getLogger() ADMIN_NAME='vilmibm' -EXTERNAL_FROM='tildetown@protonmail.ch' +EXTERNAL_FROM='root@tilde.town' +REPLY_TO='tildetown@protonmail.ch' def send_email(to, body, subject='a message from tilde.town'): """Sends an email using mailgun. Logs on failure.""" @@ -16,6 +17,7 @@ def send_email(to, body, subject='a message from tilde.town'): auth=('api', settings.MAILGUN_KEY), data={ 'from': EXTERNAL_FROM, + 'h:Reply-To': REPLY_TO, 'to': to, 'subject': subject, 'text': body