From 78e51f76c753742ced527ceaf118b78bc7aeef90 Mon Sep 17 00:00:00 2001 From: relativisticelectron <60378539+relativisticelectron@users.noreply.github.com> Date: Thu, 21 Jul 2022 21:06:20 +0200 Subject: [PATCH] Bugfix: startup issues for MacOS App 1815 (#1816) fix for https://github.com/cryptoadvance/specter-desktop/issues/1815 --- src/cryptoadvance/specter/htmlsafebabel.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/cryptoadvance/specter/htmlsafebabel.py b/src/cryptoadvance/specter/htmlsafebabel.py index 65c3d5a3f0..b8b091d0d0 100644 --- a/src/cryptoadvance/specter/htmlsafebabel.py +++ b/src/cryptoadvance/specter/htmlsafebabel.py @@ -1,6 +1,6 @@ from flask_babel import Babel, get_translations from jinja2.utils import markupsafe -from html.parser import HTMLParser +import html class HTMLSafeBabel(Babel): @@ -30,4 +30,4 @@ def reescape_string(escaped_string): Existing entities need to be decoded first to avoid double-encoding. """ - return markupsafe.Markup.escape(HTMLParser().unescape(escaped_string)) + return markupsafe.Markup.escape(html.unescape(escaped_string))