mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2025-01-31 22:35:20 +01:00
Fix --check-formats
Bug in bc344cd456380999c1ee74554dfd432a38f32ec7
This commit is contained in:
parent
3f7965105d
commit
8cb7fc44db
@ -2339,13 +2339,13 @@ class YoutubeDL:
|
||||
return new_dict
|
||||
|
||||
def _check_formats(formats):
|
||||
if (self.params.get('check_formats') is not None
|
||||
if self.params.get('check_formats') == 'selected':
|
||||
yield from self._check_formats(formats)
|
||||
return
|
||||
elif (self.params.get('check_formats') is not None
|
||||
or self.params.get('allow_unplayable_formats')):
|
||||
yield from formats
|
||||
return
|
||||
elif self.params.get('check_formats') == 'selected':
|
||||
yield from self._check_formats(formats)
|
||||
return
|
||||
|
||||
for f in formats:
|
||||
if f.get('has_drm'):
|
||||
|
Loading…
x
Reference in New Issue
Block a user