Browse Source
[extractor/common] Use source URL as Referer for HTML5 entries (closes #16849)
master
Sergey M․
6 years ago
No known key found for this signature in database
GPG Key ID: 2C393E0F18A9236D
1 changed files with
2 additions and
0 deletions
-
youtube_dl/extractor/common.py
|
|
@ -2437,6 +2437,8 @@ class InfoExtractor(object): |
|
|
|
media_info['subtitles'].setdefault(lang, []).append({ |
|
|
|
'url': absolute_url(src), |
|
|
|
}) |
|
|
|
for f in media_info['formats']: |
|
|
|
f.setdefault('http_headers', {})['Referer'] = base_url |
|
|
|
if media_info['formats'] or media_info['subtitles']: |
|
|
|
entries.append(media_info) |
|
|
|
return entries |
|
|
|