From 1f73f634e86b26b6161976ae6c2b5d71f7bf6c5d Mon Sep 17 00:00:00 2001 From: miruka Date: Wed, 3 Jul 2019 18:36:03 -0400 Subject: [PATCH] Strip leading/trailing \n from html filter output --- src/python/html_filter.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/python/html_filter.py b/src/python/html_filter.py index 13c59f22..0c511891 100644 --- a/src/python/html_filter.py +++ b/src/python/html_filter.py @@ -50,7 +50,7 @@ class HtmlFilter: result = b"".join((etree.tostring(el, encoding="utf-8") for el in tree[0].iterchildren())) - return str(result, "utf-8") + return str(result, "utf-8").strip("\n") @property