aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYen Chi Hsuan <yan12125@gmail.com>2016-04-29 22:49:04 +0800
committerYen Chi Hsuan <yan12125@gmail.com>2016-04-29 22:50:16 +0800
commite9c6cdf4a103d1ebdb6927bdab429c370cbe66b2 (patch)
tree9ed9f532ad3699e18145885cae42b5666545adb5
parent00a17a9e1234ecc868a15b5759472a0f9215f797 (diff)
downloadyoutube-dl-e9c6cdf4a103d1ebdb6927bdab429c370cbe66b2.tar.xz
[common] Fix format_id construction for HLS
-rw-r--r--youtube_dl/extractor/common.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/youtube_dl/extractor/common.py b/youtube_dl/extractor/common.py
index 2763d2ffe..61a5d124c 100644
--- a/youtube_dl/extractor/common.py
+++ b/youtube_dl/extractor/common.py
@@ -1142,7 +1142,7 @@ class InfoExtractor(object):
# Bandwidth of live streams may differ over time thus making
# format_id unpredictable. So it's better to keep provided
# format_id intact.
- if last_media_name and not live:
+ if not live:
format_id.append(last_media_name if last_media_name else '%d' % (tbr if tbr else len(formats)))
f = {
'format_id': '-'.join(format_id),