1
0
Fork 0
mirror of https://github.com/ytdl-org/youtube-dl.git synced 2024-11-26 20:22:14 +00:00

[youtube] remove dead code

This commit is contained in:
Philipp Hagemeister 2013-06-23 19:59:40 +02:00
parent c5e8d7af0e
commit 93d3a642a9

View file

@ -343,7 +343,7 @@ class YoutubeIE(InfoExtractor):
request = compat_urllib_request.Request(self._AGE_URL, compat_urllib_parse.urlencode(age_form)) request = compat_urllib_request.Request(self._AGE_URL, compat_urllib_parse.urlencode(age_form))
try: try:
self.report_age_confirmation() self.report_age_confirmation()
age_results = compat_urllib_request.urlopen(request).read().decode('utf-8') compat_urllib_request.urlopen(request).read().decode('utf-8')
except (compat_urllib_error.URLError, compat_http_client.HTTPException, socket.error) as err: except (compat_urllib_error.URLError, compat_http_client.HTTPException, socket.error) as err:
raise ExtractorError(u'Unable to confirm age: %s' % compat_str(err)) raise ExtractorError(u'Unable to confirm age: %s' % compat_str(err))
@ -471,7 +471,7 @@ class YoutubeIE(InfoExtractor):
self._downloader.report_warning(sub_error) self._downloader.report_warning(sub_error)
if self._downloader.params.get('listsubtitles', False): if self._downloader.params.get('listsubtitles', False):
sub_lang_list = self._list_available_subtitles(video_id) self._list_available_subtitles(video_id)
return return
if 'length_seconds' not in video_info: if 'length_seconds' not in video_info:
@ -480,9 +480,6 @@ class YoutubeIE(InfoExtractor):
else: else:
video_duration = compat_urllib_parse.unquote_plus(video_info['length_seconds'][0]) video_duration = compat_urllib_parse.unquote_plus(video_info['length_seconds'][0])
# token
video_token = compat_urllib_parse.unquote_plus(video_info['token'][0])
# Decide which formats to download # Decide which formats to download
req_format = self._downloader.params.get('format', None) req_format = self._downloader.params.get('format', None)