Debug for DLHD

This commit is contained in:
UrloMythus
2024-09-29 14:28:16 +02:00 Unverified
parent 4f3f9c5a04
commit 0a5a8c6269
2 changed files with 4 additions and 3 deletions
-1
View File
@@ -42,7 +42,6 @@ async def webru(id,site,client):
mediaproxy = config.MediaProxy
medialink = random.choice(mediaproxy)
new_stream_url = f'{medialink}proxy/hls?key_url=https%3A%2F%2Fkey.mizhls.ru%2F&api_password={MEDIAFLOW_PASS}&d={stream_url}&h_Referer={Referer}&h_Origin={Origin}&h_User-Agent=Mozilla%2F5.0%20(Windows%20NT%2010.0%3B%20Win64%3B%20x64)%20AppleWebKit%2F537.36%20(KHTML%2C%20like%20Gecko)%20Chrome%2F58.0.3029.110%20Safari%2F537.3'
print(new_stream_url)
return new_stream_url
except Exception as e:
print("WebRu failed",e)
+4 -2
View File
@@ -208,9 +208,11 @@ async def addon_stream(request: Request,config, type, id,):
streams['streams'].append({'title': f"{HF}Server {i} " + channel['title'],'url': webru_url})
if id in webru_dlhd:
if DLHD == "1":
print("Webru DLHD triggered")
i = i+1
webru_url = await webru(id,"dlhd",client)
streams['streams'].append({'title': f"{HF}Server {i} " + channel['title'],'url': webru_url})
webru_url_2 = await webru(id,"dlhd",client)
print(webru_url_2)
streams['streams'].append({'title': f"{HF}Server {i} " + channel['title'],'url': webru_url_2})
if not streams['streams']:
raise HTTPException(status_code=404)
return respond_with(streams)