summaryrefslogtreecommitdiffstats
path: root/gallery_dl/extractor/scrolller.py
diff options
context:
space:
mode:
authorLibravatarUnit 193 <unit193@unit193.net>2024-12-02 00:31:59 -0500
committerLibravatarUnit 193 <unit193@unit193.net>2024-12-02 00:31:59 -0500
commit1981ccaaea6eab2cf32536ec5afe132a870914d8 (patch)
tree013f1e17d922d3a6abf7f57aa6a175c2ce5d93bc /gallery_dl/extractor/scrolller.py
parentfc004701f923bb954a22c7fec2ae8d607e78cb2b (diff)
New upstream version 1.28.0.upstream/1.28.0
Diffstat (limited to 'gallery_dl/extractor/scrolller.py')
-rw-r--r--gallery_dl/extractor/scrolller.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/gallery_dl/extractor/scrolller.py b/gallery_dl/extractor/scrolller.py
index 9f9f0c4..c818c98 100644
--- a/gallery_dl/extractor/scrolller.py
+++ b/gallery_dl/extractor/scrolller.py
@@ -32,7 +32,12 @@ class ScrolllerExtractor(Extractor):
for post in self.posts():
- src = max(post["mediaSources"], key=self._sort_key)
+ media_sources = post.get("mediaSources")
+ if not media_sources:
+ self.log.warning("%s: No media files", post.get("id"))
+ continue
+
+ src = max(media_sources, key=self._sort_key)
post.update(src)
url = src["url"]
text.nameext_from_url(url, post)