mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2024-11-17 21:59:17 +00:00
[youtube] Correctly disable polymer on all requests
Rather than just the one that use the _download_webpage helper. The need
for this was made apparent by 0fe7783e
, which refactored
_download_json in a way that completely avoids the use of
_download_webpage, thus breaking youtube.
Fixes #16323
This commit is contained in:
parent
01aec84880
commit
30226342ab
|
@ -246,9 +246,9 @@ def warn(message):
|
||||||
|
|
||||||
return True
|
return True
|
||||||
|
|
||||||
def _download_webpage(self, *args, **kwargs):
|
def _download_webpage_handle(self, *args, **kwargs):
|
||||||
kwargs.setdefault('query', {})['disable_polymer'] = 'true'
|
kwargs.setdefault('query', {})['disable_polymer'] = 'true'
|
||||||
return super(YoutubeBaseInfoExtractor, self)._download_webpage(
|
return super(YoutubeBaseInfoExtractor, self)._download_webpage_handle(
|
||||||
*args, **compat_kwargs(kwargs))
|
*args, **compat_kwargs(kwargs))
|
||||||
|
|
||||||
def _real_initialize(self):
|
def _real_initialize(self):
|
||||||
|
|
Loading…
Reference in a new issue