[fix] html.unescape stract autocomplete suggestions

This commit is contained in:
Allen 2024-07-01 16:45:20 +00:00 committed by GitHub
parent 0fb3f0e4ae
commit cf49ccb71c

View file

@ -5,6 +5,7 @@
# pylint: disable=use-dict-literal
import json
import html
from urllib.parse import urlencode, quote_plus
import lxml
@ -162,7 +163,7 @@ def stract(query, _lang):
if not resp.ok:
return []
return [suggestion['raw'] for suggestion in resp.json()]
return [html.unescape(suggestion['raw']) for suggestion in resp.json()]
def startpage(query, sxng_locale):