diff --git a/svtplay_dl.py b/svtplay_dl.py index 065fbed..9923a9c 100755 --- a/svtplay_dl.py +++ b/svtplay_dl.py @@ -794,6 +794,7 @@ class Urplay(): data = re.sub("(\w+): ", r'"\1":',data.group(1)) data = data.replace("\'", "\"").replace("\",}","\"}").replace("(m = location.hash.match(/[#&]start=(\d+)/)) ? m[1] : 0,","0") jsondata = json.loads(data) + subtitle = jsondata["subtitles"].split(",")[0] basedomain = jsondata["streaming_config"]["streamer"]["redirect"] http = "http://%s/%s" % (basedomain, jsondata["file_html5"]) hds = "%s%s" % (http, jsondata["streaming_config"]["http_streaming"]["hds_file"]) @@ -805,6 +806,8 @@ class Urplay(): download_hls(options, hls, http) else: download_rtmp(options, rtmp) + if options.subtitle: + subtitle_tt(options, subtitle) class Qbrick(): def handle(self, url):