mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2024-11-30 17:49:34 -05:00
[YoutubeDL] set the 'thumbnails' field if the info_dict has the 'thumbnails' field
Since the '--write-thumbnail' uses the 'thumbnails' field and we didn't updated the info_dict, it wouldn't detect the thumbnail. (fixes #4812)
This commit is contained in:
parent
219337990b
commit
a7a14d9586
1 changed files with 1 additions and 1 deletions
|
@ -958,7 +958,7 @@ def process_video_result(self, info_dict, download=True):
|
||||||
if thumbnails is None:
|
if thumbnails is None:
|
||||||
thumbnail = info_dict.get('thumbnail')
|
thumbnail = info_dict.get('thumbnail')
|
||||||
if thumbnail:
|
if thumbnail:
|
||||||
thumbnails = [{'url': thumbnail}]
|
info_dict['thumbnails'] = thumbnails = [{'url': thumbnail}]
|
||||||
if thumbnails:
|
if thumbnails:
|
||||||
thumbnails.sort(key=lambda t: (
|
thumbnails.sort(key=lambda t: (
|
||||||
t.get('preference'), t.get('width'), t.get('height'),
|
t.get('preference'), t.get('width'), t.get('height'),
|
||||||
|
|
Loading…
Reference in a new issue