From 8bcbd5dad4e7f1177cae630366b476287c617a19 Mon Sep 17 00:00:00 2001 From: Johan Andersson Date: Wed, 12 May 2021 21:00:00 +0200 Subject: [PATCH] urplay: fix a crash when getting subtitle. for some reason they remove which one is default. now we assume that swedish is the one fixes: #1382 --- lib/svtplay_dl/service/urplay.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/svtplay_dl/service/urplay.py b/lib/svtplay_dl/service/urplay.py index 0ff5faa..2935a99 100644 --- a/lib/svtplay_dl/service/urplay.py +++ b/lib/svtplay_dl/service/urplay.py @@ -49,7 +49,7 @@ class Urplay(Service, OpenGraphThumbMixin): streams = hlsparse(self.config, self.http.request("get", url), url, output=self.output) for n in list(streams.keys()): yield streams[n] - if not (self.config.get("get_all_subtitles")) and (stream["default"]): + if not (self.config.get("get_all_subtitles")) and streaminfo == "sweComplete": yield subtitle(copy.copy(self.config), "wrst", stream["tt"]["location"].replace(".tt", ".vtt"), output=self.output) if self.config.get("get_all_subtitles") and "tt" in stream: