aboutsummaryrefslogtreecommitdiffstats
path: root/yt_dlp/extractor/radiko.py
diff options
context:
space:
mode:
authorpukkandan <pukkandan.ytdlp@gmail.com>2023-02-17 17:52:22 +0530
committerpukkandan <pukkandan.ytdlp@gmail.com>2023-02-17 17:52:22 +0530
commita5387729696a5b33f53f60ef06f48e45663b12dd (patch)
tree8fd95812256275308fd114a4453c42253b94ea81 /yt_dlp/extractor/radiko.py
parent30031be974d210f451100339699ef03b0ddb5f10 (diff)
downloadhypervideo-pre-a5387729696a5b33f53f60ef06f48e45663b12dd.tar.lz
hypervideo-pre-a5387729696a5b33f53f60ef06f48e45663b12dd.tar.xz
hypervideo-pre-a5387729696a5b33f53f60ef06f48e45663b12dd.zip
[cleanup] Misc
Closes #5897
Diffstat (limited to 'yt_dlp/extractor/radiko.py')
-rw-r--r--yt_dlp/extractor/radiko.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/yt_dlp/extractor/radiko.py b/yt_dlp/extractor/radiko.py
index 43eecba5f..7fdf78283 100644
--- a/yt_dlp/extractor/radiko.py
+++ b/yt_dlp/extractor/radiko.py
@@ -133,9 +133,9 @@ class RadikoBaseIE(InfoExtractor):
'X-Radiko-AreaId': area_id,
'X-Radiko-AuthToken': auth_token,
})
- not_preferred = is_onair and not pcu.startswith(self._HOSTS_FOR_LIVE) or (not is_onair and (pcu.startswith(self._HOSTS_FOR_TIME_FREE_FFMPEG_UNSUPPORTED) or pcu.startswith(self._HOSTS_FOR_LIVE)))
for sf in subformats:
- if not_preferred:
+ if (is_onair ^ pcu.startswith(self._HOSTS_FOR_LIVE)) or (
+ not is_onair and pcu.startswith(self._HOSTS_FOR_TIME_FREE_FFMPEG_UNSUPPORTED)):
sf['preference'] = -100
sf['format_note'] = 'not preferred'
if not is_onair and url_attrib['timefree'] == '1' and time_to_skip: