From 709e789ade88bbc15f0500dd8c66e9c5efae7ca7 Mon Sep 17 00:00:00 2001 From: abdo Date: Sun, 11 Oct 2020 16:09:56 +0300 Subject: [PATCH] Decode pasted URLs --- qt/aqt/editor.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/qt/aqt/editor.py b/qt/aqt/editor.py index b81103b1e..105c0a0e6 100644 --- a/qt/aqt/editor.py +++ b/qt/aqt/editor.py @@ -1130,7 +1130,9 @@ class EditorWebView(AnkiWebView): processed.append(link) else: # not media; add it as a normal link - link = '{}'.format(token, html.escape(token)) + link = '{}'.format( + token, html.escape(urllib.parse.unquote(token)) + ) processed.append(link) else: token = html.escape(token).replace("\t", " " * 4)