Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b422788e authored by Adam Tauber's avatar Adam Tauber
Browse files

[fix] wikipedia autocompleter url param

parent ee8cabf4
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -69,7 +69,7 @@ def wikipedia(query):
    # wikipedia autocompleter
    url = 'https://en.wikipedia.org/w/api.php?action=opensearch&{0}&limit=10&namespace=0&format=json'  # noqa

    resp = loads(get(url.format(urlencode(dict(q=query)))).text)
    resp = loads(get(url.format(urlencode(dict(search=query)))).text)
    if len(resp) > 1:
        return resp[1]
    return []