mirror of
https://github.com/RicterZ/nhentai.git
synced 2025-04-19 10:21:19 +02:00
fix bug #265
This commit is contained in:
parent
e08b0659e5
commit
e89c2c0860
@ -184,7 +184,7 @@ def legacy_search_parser(keyword, sorting, page, is_page_all=False):
|
||||
response = None
|
||||
result = []
|
||||
|
||||
if is_page_all:
|
||||
if is_page_all and len(page) != 1:
|
||||
# `--page-all` option will override the `--page` option
|
||||
page = [1]
|
||||
|
||||
@ -208,7 +208,7 @@ def legacy_search_parser(keyword, sorting, page, is_page_all=False):
|
||||
return result
|
||||
else:
|
||||
next_page = re.findall('page=([0-9]+)', next_page.attrs['href'])[0]
|
||||
result.extend(legacy_search_parser(keyword, sorting, next_page, is_page_all))
|
||||
result.extend(legacy_search_parser(keyword, sorting, [next_page], is_page_all))
|
||||
return result
|
||||
|
||||
return result
|
||||
|
Loading…
x
Reference in New Issue
Block a user