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

Commit 00512e36 authored by Adam Tauber's avatar Adam Tauber
Browse files

[fix] handle empty response from wikipedia engine - closes #1114

parent f8713512
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -79,6 +79,9 @@ def response(resp):

    # wikipedia article's unique id
    # first valid id is assumed to be the requested article
    if 'pages' not in search_result['query']:
        return results

    for article_id in search_result['query']['pages']:
        page = search_result['query']['pages'][article_id]
        if int(article_id) > 0: