From c5e6be02e6a5bfaf838d9461380b52a51442165c Mon Sep 17 00:00:00 2001 From: Johan Andersson Date: Tue, 12 Sep 2017 12:33:49 +0200 Subject: [PATCH] tv4play: fix auto naming for latest version of the site --- lib/svtplay_dl/service/tv4play.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/lib/svtplay_dl/service/tv4play.py b/lib/svtplay_dl/service/tv4play.py index 974081f..bb24b1d 100644 --- a/lib/svtplay_dl/service/tv4play.py +++ b/lib/svtplay_dl/service/tv4play.py @@ -156,7 +156,12 @@ class Tv4play(Service, OpenGraphThumbMixin): parse = urlparse(self.url) if parse.path.count("/") > 2: match = re.search("^/([^/]+)/", parse.path) - show = match.group(1) + if "program" == match.group(1): + match = re.search("^/program/([^/]+)/", parse.path) + if match: + show = match.group(1) + else: + show = match.group(1) else: show = parse.path[parse.path.find("/", 1)+1:] if not re.search("%", show):