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

Better fix for DN.se

This commit is contained in:
Johan Andersson 2012-02-16 09:58:14 +01:00
parent e14009bf02
commit ff7e9f5855

View File

@ -601,11 +601,16 @@ def main():
elif re.findall("dn.se", url):
data = common.getdata(url)
match = re.search("data-qbrick-mcid=\"([0-9A-F]+)\"", data)
if not match:
match = re.search("mediaId = \'([0-9A-F]+)\';", data)
if not match:
print("Something wrong with that url")
sys.exit(2)
mcid = match.group(1) + "DE1BA107"
else:
mcid = match.group(1)
qbrick = Qbrick(output, quality, live, resume)
host = "http://vms.api.qbrick.com/rest/v3/getsingleplayer/" + match.group(1)
host = "http://vms.api.qbrick.com/rest/v3/getsingleplayer/" + mcid
data = common.getdata(host)
xml = ET.XML(data)
try: