1
1
mirror of https://github.com/ytdl-org/youtube-dl synced 2024-11-24 09:16:50 +01:00

[youtube] Support videos without a title (Fixes #1391, Closes #1542)

This commit is contained in:
Philipp Hagemeister 2013-10-02 07:25:35 +02:00
parent bd8e5c7ca2
commit a8c6b24155

View File

@ -1334,9 +1334,11 @@ class YoutubeIE(YoutubeBaseInfoExtractor, SubtitlesInfoExtractor):
self._downloader.report_warning(u'unable to extract uploader nickname')
# title
if 'title' not in video_info:
raise ExtractorError(u'Unable to extract video title')
video_title = compat_urllib_parse.unquote_plus(video_info['title'][0])
if 'title' in video_info:
video_title = compat_urllib_parse.unquote_plus(video_info['title'][0])
else:
self._downloader.report_warning(u'Unable to extract video title')
video_title = u'_'
# thumbnail image
# We try first to get a high quality image: