mirror of
https://github.com/spaam/svtplay-dl.git
synced 2024-11-24 04:05:39 +01:00
svtplay: subtitles didn’t get the right filename
This commit is contained in:
parent
dde85fb7fb
commit
063242b365
@ -54,14 +54,6 @@ class Svtplay(Service, OpenGraphThumbMixin):
|
||||
else:
|
||||
options.live = False
|
||||
|
||||
if data["video"]["subtitleReferences"]:
|
||||
try:
|
||||
suburl = data["video"]["subtitleReferences"][0]["url"]
|
||||
except KeyError:
|
||||
pass
|
||||
if suburl and len(suburl) > 0:
|
||||
yield subtitle(copy.copy(options), "wrst", suburl)
|
||||
|
||||
if options.output_auto:
|
||||
directory = os.path.dirname(options.output)
|
||||
options.service = "svtplay"
|
||||
@ -77,6 +69,14 @@ class Svtplay(Service, OpenGraphThumbMixin):
|
||||
else:
|
||||
options.output = title
|
||||
|
||||
if data["video"]["subtitleReferences"]:
|
||||
try:
|
||||
suburl = data["video"]["subtitleReferences"][0]["url"]
|
||||
except KeyError:
|
||||
pass
|
||||
if suburl and len(suburl) > 0:
|
||||
yield subtitle(copy.copy(options), "wrst", suburl)
|
||||
|
||||
if options.force_subtitle:
|
||||
return
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user