From 6f11b61cd5eebd0d9b046be20f4f225803279c67 Mon Sep 17 00:00:00 2001 From: Alexandre Flament Date: Mon, 13 Sep 2021 08:37:25 +0200 Subject: [PATCH] [fix] openstreetmap engine: map "all" language to English --- searx/engines/openstreetmap.py | 1 + 1 file changed, 1 insertion(+) diff --git a/searx/engines/openstreetmap.py b/searx/engines/openstreetmap.py index 9f1fe94c9..07d536725 100644 --- a/searx/engines/openstreetmap.py +++ b/searx/engines/openstreetmap.py @@ -220,6 +220,7 @@ def fetch_wikidata(nominatim_json, user_langage): wd_to_results.setdefault(wd_id, []).append(result) if wikidata_ids: + user_langage = 'en' if user_langage == 'all' else user_langage wikidata_ids_str = " ".join(wikidata_ids) query = wikidata_image_sparql.replace('%WIKIDATA_IDS%', sparql_string_escape(wikidata_ids_str)).replace( '%LANGUAGE%', sparql_string_escape(user_langage)