1
0
mirror of https://github.com/spaam/svtplay-dl.git synced 2024-11-23 19:55:38 +01:00

Compare commits

..

5 Commits

Author SHA1 Message Date
I'm an OSK user, are you?
023c4ef305
Merge c81de1f693 into 2383b26e1b 2024-11-21 01:46:54 +00:00
Johan Andersson
2383b26e1b Revert "pre-commit: update"
This reverts commit 7e10813ae3.
2024-11-08 18:23:26 +01:00
Johan Andersson
1f55f8cb3f pre-commit: rollback black to earlier version 2024-11-08 18:20:31 +01:00
Johan Andersson
7e10813ae3 pre-commit: update 2024-11-08 10:32:04 +01:00
Johan Andersson
a69c8c8ccc svtplay: fix a crash on pages with upcoming videos 2024-11-08 10:29:58 +01:00

View File

@ -114,6 +114,9 @@ class Svtplay(Service, MetadataThumbMixin):
subfix = lang subfix = lang
yield from subtitle_probe(copy.copy(self.config), i["url"], subfix=subfix, output=self.output) yield from subtitle_probe(copy.copy(self.config), i["url"], subfix=subfix, output=self.output)
if not janson["videoReferences"]:
yield ServiceError("Media doesn't have any associated videos.")
return
drm = janson["rights"]["drmCopyProtection"] drm = janson["rights"]["drmCopyProtection"]
if not drm and "variants" in janson and "default" in janson["variants"]: if not drm and "variants" in janson and "default" in janson["variants"]:
if len(janson["videoReferences"]) == 0: if len(janson["videoReferences"]) == 0: