1
1
mirror of https://github.com/ytdl-org/youtube-dl synced 2024-12-25 04:16:03 +01:00

Incorrect variable is used to check whether thumbnail exists

Dear @phihag

I believe in line 848, the correct variable to check is 'thumb_filename' rather than 'infofn'

Kindly advise

Mit freundlichen Gruessen
Ali
This commit is contained in:
alimirjamali 2013-12-16 20:14:28 +03:30
parent 4b2da48ea7
commit 0a9ce268ba

View File

@ -845,7 +845,7 @@ class YoutubeDL(object):
if info_dict.get('thumbnail') is not None:
thumb_format = determine_ext(info_dict['thumbnail'], u'jpg')
thumb_filename = os.path.splitext(filename)[0] + u'.' + thumb_format
if self.params.get('nooverwrites', False) and os.path.exists(encodeFilename(infofn)):
if self.params.get('nooverwrites', False) and os.path.exists(encodeFilename(thumb_filename)):
self.to_screen(u'[%s] %s: Thumbnail is already present' %
(info_dict['extractor'], info_dict['id']))
else: