[YoutubeDL] Fix playlist entry indexing with --playlist-items (closes #10591, closes #10622)

This commit is contained in:
jxu 2020-01-28 05:20:19 -05:00 committed by Sergey M․
parent 293c9f0186
commit de1121d749
No known key found for this signature in database
GPG key ID: 2C393E0F18A9236D

View file

@ -990,7 +990,7 @@ def report_download(num_entries):
'playlist_title': ie_result.get('title'), 'playlist_title': ie_result.get('title'),
'playlist_uploader': ie_result.get('uploader'), 'playlist_uploader': ie_result.get('uploader'),
'playlist_uploader_id': ie_result.get('uploader_id'), 'playlist_uploader_id': ie_result.get('uploader_id'),
'playlist_index': i + playliststart, 'playlist_index': playlistitems[i - 1] if playlistitems else i + playliststart,
'extractor': ie_result['extractor'], 'extractor': ie_result['extractor'],
'webpage_url': ie_result['webpage_url'], 'webpage_url': ie_result['webpage_url'],
'webpage_url_basename': url_basename(ie_result['webpage_url']), 'webpage_url_basename': url_basename(ie_result['webpage_url']),