Rferer corretto per i link diretti (fix animesaturn)

This commit is contained in:
marco
2022-02-03 19:42:16 +01:00
parent 1d9b5c9dd1
commit 788cfcff22
+2 -1
View File
@@ -1018,7 +1018,8 @@ def play_video(item, strm=False, force_direct=False, autoplay=False):
# we get the selected video # we get the selected video
mediaurl, view, mpd, hls = get_video_seleccionado(item, seleccion, video_urls, autoplay) mediaurl, view, mpd, hls = get_video_seleccionado(item, seleccion, video_urls, autoplay)
if not mediaurl: return if not mediaurl: return
headers = {'User-Agent': httptools.get_user_agent(), 'Referer': item.url} # to better disguise KoD as a browser
headers = {'User-Agent': httptools.get_user_agent(), 'Referer': item.referer if item.server == 'directo' else item.url}
# Kodi does not seems to allow this, leaving there as may work in the future # Kodi does not seems to allow this, leaving there as may work in the future
# if config.get_setting('resolver_dns'): # if config.get_setting('resolver_dns'):
# try: # try: