From 96121e57f30c44f2604d1c277cb7dc9b91537b16 Mon Sep 17 00:00:00 2001 From: Thomas Sileo Date: Sun, 1 Sep 2019 10:45:18 +0200 Subject: [PATCH] Fix BeautifulSoup warning --- utils/highlight.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/utils/highlight.py b/utils/highlight.py index 74fa16f..66352b4 100644 --- a/utils/highlight.py +++ b/utils/highlight.py @@ -22,7 +22,7 @@ def highlight(html: str) -> str: if not code.parent.name == "pre": continue lexer = guess_lexer(code.text) - tag = BeautifulSoup(phighlight(code.text, lexer, _FORMATTER)).body.next + tag = BeautifulSoup(phighlight(code.text, lexer, _FORMATTER), "html5lib").body.next pre = code.parent pre.replaceWith(tag) out = soup.body