[inkbunny] add 'sid' parameter to private file downloads

(fixes #1281)
This commit is contained in:
Mike Fährmann 2021-01-28 15:45:48 +01:00
parent c6cc86d7d0
commit e61b125fcc
No known key found for this signature in database
GPG Key ID: 5680CA389D365A88

View File

@ -54,7 +54,11 @@ class InkbunnyExtractor(Extractor):
post["date"] = text.parse_datetime(
file["create_datetime"] + "00", "%Y-%m-%d %H:%M:%S.%f%z")
text.nameext_from_url(file["file_name"], post)
yield Message.Url, file["file_url_full"], post
url = file["file_url_full"]
if "/private_files/" in url:
url += "?sid=" + self.api.session_id
yield Message.Url, url, post
class InkbunnyUserExtractor(InkbunnyExtractor):