mirror of
https://github.com/mikf/gallery-dl.git
synced 2024-11-25 04:02:32 +01:00
Fix infinite loop in Weasyl Favs downloader
This commit is contained in:
parent
10543c64c6
commit
cbecaecc43
@ -192,9 +192,11 @@ class WeasylFavoriteExtractor(WeasylExtractor):
|
|||||||
if not owner_login:
|
if not owner_login:
|
||||||
owner_login = text.extr(page, '<a href="/~', '"')
|
owner_login = text.extr(page, '<a href="/~', '"')
|
||||||
|
|
||||||
|
new_posts = False
|
||||||
for submitid in text.extract_iter(page, "/submissions/", "/", pos):
|
for submitid in text.extract_iter(page, "/submissions/", "/", pos):
|
||||||
if submitid == lastid:
|
if submitid == lastid:
|
||||||
continue
|
continue
|
||||||
|
new_posts = True
|
||||||
lastid = submitid
|
lastid = submitid
|
||||||
submission = self.request_submission(submitid)
|
submission = self.request_submission(submitid)
|
||||||
if self.populate_submission(submission):
|
if self.populate_submission(submission):
|
||||||
@ -202,6 +204,6 @@ class WeasylFavoriteExtractor(WeasylExtractor):
|
|||||||
yield Message.Directory, submission
|
yield Message.Directory, submission
|
||||||
yield Message.Url, submission["url"], submission
|
yield Message.Url, submission["url"], submission
|
||||||
|
|
||||||
if "&nextid=" not in page:
|
if not new_posts:
|
||||||
return
|
return
|
||||||
params["nextid"] = submitid
|
params["nextid"] = submitid
|
||||||
|
Loading…
Reference in New Issue
Block a user