From 2c332edaade1b82c6c890692040b208fc8ed9ec1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mike=20F=C3=A4hrmann?= Date: Wed, 27 Nov 2019 19:39:56 +0100 Subject: [PATCH] [plurk] fix comment pagination --- gallery_dl/extractor/plurk.py | 4 +++- gallery_dl/extractor/wallhaven.py | 4 ++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/gallery_dl/extractor/plurk.py b/gallery_dl/extractor/plurk.py index 2bb66ac5..e5da60a6 100644 --- a/gallery_dl/extractor/plurk.py +++ b/gallery_dl/extractor/plurk.py @@ -53,7 +53,9 @@ class PlurkExtractor(Extractor): yield from info["responses"] if not info["has_newer"]: return - data["from_response_id"] = info["responses"][-1]["id"] + elif info["has_newer"] < 200: + del data["count"] + data["from_response_id"] = info["responses"][-1]["id"] + 1 @staticmethod def _load(data): diff --git a/gallery_dl/extractor/wallhaven.py b/gallery_dl/extractor/wallhaven.py index 09a166c3..737c2533 100644 --- a/gallery_dl/extractor/wallhaven.py +++ b/gallery_dl/extractor/wallhaven.py @@ -33,8 +33,8 @@ class WallhavenSearchExtractor(WallhavenExtractor): ("https://wallhaven.cc/search?q=touhou"), (("https://wallhaven.cc/search?q=id%3A87" "&categories=111&purity=100&sorting=date_added&order=asc&page=3"), { - "count": 5, - "url": "d477b68a534c3416d506ae1f159b25debab64678", + "pattern": r"https://w.wallhaven.cc/full/\w\w/wallhaven-\w+\.\w+", + "count": "<= 10", }), )