[patreon] support 'date-max' for '/home' URLs (#7856)
This commit is contained in:
@@ -3894,6 +3894,16 @@ Description
|
||||
* ``thumbnail_small`` (``"h":100,"w":100``)
|
||||
|
||||
|
||||
extractor.patreon.user.date-max
|
||||
-------------------------------
|
||||
Type
|
||||
|Date|_
|
||||
Default
|
||||
``0``
|
||||
Description
|
||||
Sets the |Date|_ to start from.
|
||||
|
||||
|
||||
extractor.[philomena].api-key
|
||||
-----------------------------
|
||||
Type
|
||||
|
||||
@@ -508,7 +508,11 @@
|
||||
|
||||
"cursor" : true,
|
||||
"files" : ["images", "image_large", "attachments", "postfile", "content"],
|
||||
"format-images": "download_url"
|
||||
"format-images": "download_url",
|
||||
|
||||
"user": {
|
||||
"date-max" : 0
|
||||
}
|
||||
},
|
||||
"pexels":
|
||||
{
|
||||
|
||||
@@ -407,6 +407,11 @@ class PatreonUserExtractor(PatreonExtractor):
|
||||
example = "https://www.patreon.com/home"
|
||||
|
||||
def posts(self):
|
||||
if date_max := self._get_date_min_max(None, None)[1]:
|
||||
self._cursor = cursor = \
|
||||
util.datetime_from_timestamp(date_max).isoformat()
|
||||
self._init_cursor = lambda: cursor
|
||||
|
||||
url = self._build_url("stream", (
|
||||
"&filter[is_following]=true"
|
||||
"&json-api-use-default-includes=false"
|
||||
|
||||
Reference in New Issue
Block a user