From bf28ba64cbfd2419440975b716e948dd4dedbe79 Mon Sep 17 00:00:00 2001 From: Thomas Oettli Date: Tue, 22 Oct 2019 20:33:53 +0200 Subject: [PATCH] Add p tags to whitelist and prefer text/plain --- pyquarantine/notifications.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pyquarantine/notifications.py b/pyquarantine/notifications.py index 55dce4a..835eb9f 100644 --- a/pyquarantine/notifications.py +++ b/pyquarantine/notifications.py @@ -71,6 +71,7 @@ class EMailNotification(BaseNotification): "i", "img", "li", + "p", "span", "table", "td", @@ -229,7 +230,7 @@ class EMailNotification(BaseNotification): return BeautifulSoup(text, "lxml") - def get_text_multipart(self, queueid, msg, preferred=_html_text): + def get_text_multipart(self, queueid, msg, preferred=_plain_text): "Get the mail text of a multipart email in html form." soup = None