diff options
author | Markus Heiser <markus.heiser@darmarit.de> | 2023-09-03 09:32:10 +0200 |
---|---|---|
committer | Markus Heiser <markus.heiser@darmarIT.de> | 2023-09-03 18:45:39 +0200 |
commit | 01be9e0e20206c93cd42a79e938bf45fbde079ad (patch) | |
tree | 78e6c63d285a0e7727845b9dd229e289547ea1ba /searx | |
parent | 4f8895c6de2659f9ca069dde7be8eb3714ed1494 (diff) | |
download | searxng-01be9e0e20206c93cd42a79e938bf45fbde079ad.tar.gz searxng-01be9e0e20206c93cd42a79e938bf45fbde079ad.zip |
[fix] engine: wikicommons - don't quoute ':|' in URL parameters
From [1]: It seems to be because of [2] For some reason it gets url encoded
twice, resulting in
- ``filetype%253Abitmap%257Cdrawing+birds`` instead of
- ``filetype:bitmap%7Cdrawing+birds``
[1] https://github.com/searxng/searxng/issues/2707
[2] https://github.com/searxng/searxng/blob/master/searx/engines/wikicommons.py#L43
Closes: #2707
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
Diffstat (limited to 'searx')
-rw-r--r-- | searx/engines/wikicommons.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/searx/engines/wikicommons.py b/searx/engines/wikicommons.py index 47b2a5bea..a478f57d2 100644 --- a/searx/engines/wikicommons.py +++ b/searx/engines/wikicommons.py @@ -43,7 +43,7 @@ def request(query, params): 'gsrsearch': "filetype:bitmap|drawing " + query, } - params["url"] = f"{base_url}/w/api.php{search_prefix}&{urlencode(args)}" + params["url"] = f"{base_url}/w/api.php{search_prefix}&{urlencode(args, safe=':|')}" return params |