1
0
mirror of https://github.com/spaam/svtplay-dl.git synced 2024-11-24 04:05:39 +01:00

kanal5: Send the cookies to subtitle.

super hack workaround for #178
This commit is contained in:
Johan Andersson 2014-11-16 22:09:16 +01:00
parent ad5399f5de
commit 75c508292e
2 changed files with 2 additions and 1 deletions

View File

@ -58,6 +58,7 @@ class Kanal5(Service):
url = "http://www.kanal5play.se/api/getVideo?format=FLASH&videoId=%s" % video_id
data = json.loads(get_http_data(url, cookiejar=self.cj))
options.cookiejar = self.cj
if not options.live:
options.live = data["isLive"]
if data["hasSubtitle"]:

View File

@ -44,7 +44,7 @@ class subtitle_tt(subtitle):
class subtitle_json(subtitle):
def download(self, options):
self.subtitle = get_http_data(self.url)
self.subtitle = get_http_data(self.url, cookiejar=options.cookiejar)
data = json.loads(self.subtitle)
number = 1
subs = ""