summaryrefslogtreecommitdiff
path: root/searx/engines/openstreetmap.py
diff options
context:
space:
mode:
authorAlexandre Flament <alex@al-f.net>2021-09-09 17:21:48 +0200
committerAlexandre Flament <alex@al-f.net>2021-09-13 08:47:59 +0200
commitf8793fbda031928222613c3080ec65584d860984 (patch)
tree80bc6e7876f0202ea17e3dfdbec9a45e91a7954d /searx/engines/openstreetmap.py
parent1973e4ecf691f173299fb11abc61750009bdef84 (diff)
downloadsearxng-f8793fbda031928222613c3080ec65584d860984.tar.gz
searxng-f8793fbda031928222613c3080ec65584d860984.zip
[fix] logger per engine: make .logger is always initialized
the openstreetmap engine imports code from the wikidata engine. before this commit, specific code make sure to copy the logger variable to the wikidata engine. with this commit searx.engines.load_engine makes sure the .logger is initialized. The implementation scans sys.modules for module name starting with searx.engines.
Diffstat (limited to 'searx/engines/openstreetmap.py')
-rw-r--r--searx/engines/openstreetmap.py5
1 files changed, 0 insertions, 5 deletions
diff --git a/searx/engines/openstreetmap.py b/searx/engines/openstreetmap.py
index 78c15320a..9f1fe94c9 100644
--- a/searx/engines/openstreetmap.py
+++ b/searx/engines/openstreetmap.py
@@ -438,8 +438,3 @@ def get_key_label(key_name, lang):
if labels is None:
return None
return get_label(labels, lang)
-
-
-def init(_):
- import searx.engines.wikidata # pylint: disable=import-outside-toplevel
- searx.engines.wikidata.logger = logger