A feature-rich command-line audio/video downloader
[YoutubeDL] _calc_cookies: add get_header method to _PseudoRequest (#4861)
Jaime Marquínez Ferrándizb3a286d69d2b
diff --git a/youtube_dl/YoutubeDL.py b/youtube_dl/YoutubeDL.pyindex 9605f8f99a..633e3d8a14 100755--- a/youtube_dl/YoutubeDL.py+++ b/youtube_dl/YoutubeDL.py@@ -938,6 +938,9 @@ class YoutubeDL(object):def has_header(self, h):return h in self.headers+ def get_header(self, h, default=None):+ return self.headers.get(h, default)+pr = _PseudoRequest(info_dict['url'])self.cookiejar.add_cookie_header(pr)return pr.headers.get('Cookie')