mirror of
https://github.com/searxng/searxng.git
synced 2025-12-24 04:30:02 +00:00
Drop Python 2 (4/n): SearchQuery.query is a str instead of bytes
This commit is contained in:
@@ -18,7 +18,7 @@ categories = ['general']
|
||||
url = 'https://dictzone.com/{from_lang}-{to_lang}-dictionary/{query}'
|
||||
weight = 100
|
||||
|
||||
parser_re = re.compile(b'.*?([a-z]+)-([a-z]+) ([^ ]+)$', re.I)
|
||||
parser_re = re.compile('.*?([a-z]+)-([a-z]+) ([^ ]+)$', re.I)
|
||||
results_xpath = './/table[@id="r"]/tr'
|
||||
|
||||
|
||||
@@ -37,7 +37,7 @@ def request(query, params):
|
||||
|
||||
params['url'] = url.format(from_lang=from_lang[2],
|
||||
to_lang=to_lang[2],
|
||||
query=query.decode())
|
||||
query=query)
|
||||
|
||||
return params
|
||||
|
||||
|
||||
Reference in New Issue
Block a user