From 5690e97cb9a8a84ae5927bfcb32ec0a736b5f615 Mon Sep 17 00:00:00 2001 From: Pierre-Yves Chibon Date: May 19 2015 17:52:23 +0000 Subject: [PATCH 1/2] Adjust the debugging output to print the right thing --- diff --git a/milters/comment_email_milter.py b/milters/comment_email_milter.py index 2ef55e7..1027a72 100644 --- a/milters/comment_email_milter.py +++ b/milters/comment_email_milter.py @@ -134,7 +134,7 @@ class PagureMilter(Milter.Base): tohash= msg['to'].split('@')[0].split('+')[-1] if m.hexdigest() != tohash: self.log('hash: %s' % m.hexdigest()) - self.log('tohash: %s' % msg['tohash']) + self.log('tohash: %s' % tohash) self.log('Hash does not correspond to the destination') return Milter.CONTINUE From 76c8f51fcca38c9dd9bccd3cf64ed8e10e9abaee Mon Sep 17 00:00:00 2001 From: Pierre-Yves Chibon Date: May 19 2015 17:53:03 +0000 Subject: [PATCH 2/2] Send the user's specific email, not the global one --- diff --git a/pagure/lib/notify.py b/pagure/lib/notify.py index 3ebb4e9..d512995 100644 --- a/pagure/lib/notify.py +++ b/pagure/lib/notify.py @@ -194,7 +194,7 @@ def send_email(text, subject, to_mail, smtp.sendmail( from_email, [mailto], - msg.as_string()) + lcl_msg.as_string()) except smtplib.SMTPException as err: pagure.LOG.exception(err) smtp.quit()