1
0
mirror of https://github.com/searx/searx synced 2024-12-11 08:25:27 +01:00

[fix] pep8

This commit is contained in:
Adam Tauber 2014-03-10 16:46:11 +01:00
parent 0fc481f47e
commit 3acdf3f9a1

View File

@ -15,11 +15,13 @@ suggestion_xpath = '//div[@id="satat"]//a'
paging = True paging = True
def parse_url(url_string): def parse_url(url_string):
start = url_string.find('http', url_string.find('/RU=')+1) start = url_string.find('http', url_string.find('/RU=')+1)
end = min(url_string.rfind('/RS'), url_string.rfind('/RK')) end = min(url_string.rfind('/RS'), url_string.rfind('/RK'))
return unquote(url_string[start:end]) return unquote(url_string[start:end])
def request(query, params): def request(query, params):
offset = (params['pageno'] - 1) * 10 + 1 offset = (params['pageno'] - 1) * 10 + 1
if params['language'] == 'all': if params['language'] == 'all':