Compare commits
4 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
49bc12f93b
|
|||
|
0dd09e2d5a
|
|||
|
ec9a2e875b
|
|||
|
7a31c01955
|
@@ -118,7 +118,8 @@ def list_quarantine_emails(config, args):
|
|||||||
metadata["date"]))
|
metadata["date"]))
|
||||||
row["mailfrom"] = metadata["mailfrom"]
|
row["mailfrom"] = metadata["mailfrom"]
|
||||||
row["recipient"] = metadata["recipients"].pop(0)
|
row["recipient"] = metadata["recipients"].pop(0)
|
||||||
row["subject"] = emails[quarantine_id]["headers"]["subject"][:60]
|
if "subject" not in emails[quarantine_id]["headers"].keys():
|
||||||
|
emails[quarantine_id]["headers"]["subject"] = ""
|
||||||
rows.append(row)
|
rows.append(row)
|
||||||
|
|
||||||
if metadata["recipients"]:
|
if metadata["recipients"]:
|
||||||
|
|||||||
@@ -353,7 +353,12 @@ class EMailNotification(BaseNotification):
|
|||||||
"{}: generating notification email for '{}'".format(
|
"{}: generating notification email for '{}'".format(
|
||||||
queueid, recipient))
|
queueid, recipient))
|
||||||
self.logger.debug("{}: parsing email template".format(queueid))
|
self.logger.debug("{}: parsing email template".format(queueid))
|
||||||
|
if "from" not in headers.keys():
|
||||||
|
headers["from"] = ""
|
||||||
|
if "to" not in headers.keys():
|
||||||
|
headers["to"] = ""
|
||||||
|
if "subject" not in headers.keys():
|
||||||
|
headers["subject"] = ""
|
||||||
# generate dict containing all template variables
|
# generate dict containing all template variables
|
||||||
variables = defaultdict(str,
|
variables = defaultdict(str,
|
||||||
EMAIL_HTML_TEXT=sanitized_text,
|
EMAIL_HTML_TEXT=sanitized_text,
|
||||||
|
|||||||
@@ -1 +1 @@
|
|||||||
__version__ = "0.0.5"
|
__version__ = "0.0.7"
|
||||||
|
|||||||
Reference in New Issue
Block a user