1
0
mirror of https://github.com/spaam/svtplay-dl.git synced 2024-11-27 21:54:17 +01:00

svtplay: use parse_qs instead of regex to parse the query

This commit is contained in:
Johan Andersson 2018-02-21 23:04:20 -05:00
parent 3a1735144c
commit 6d3c57a667

View File

@ -187,9 +187,9 @@ class Svtplay(Service, OpenGraphThumbMixin):
videos = self._genre(dataj)
else:
if parse.query:
match = re.search("tab=(.+)", parse.query)
if match:
tab = match.group(1)
query = parse_qs(parse.query)
if "tab" in query:
tab = query["tab"][0]
if dataj["relatedVideoContent"]:
items = dataj["relatedVideoContent"]["relatedVideosAccordion"]