[youtube] Simplify
This commit is contained in:
parent
51f1244600
commit
8f02ad4f12
1 changed files with 2 additions and 4 deletions
|
@ -1397,20 +1397,18 @@ class YoutubeChannelIE(InfoExtractor):
|
||||||
if autogenerated:
|
if autogenerated:
|
||||||
# The videos are contained in a single page
|
# The videos are contained in a single page
|
||||||
# the ajax pages can't be used, they are empty
|
# the ajax pages can't be used, they are empty
|
||||||
videos = self.extract_videos_from_page(channel_page)
|
|
||||||
entries = [
|
entries = [
|
||||||
self.url_result(
|
self.url_result(
|
||||||
video_id, 'Youtube', video_id=video_id,
|
video_id, 'Youtube', video_id=video_id,
|
||||||
video_title=video_title)
|
video_title=video_title)
|
||||||
for video_id, video_title in videos]
|
for video_id, video_title in self.extract_videos_from_page(channel_page)]
|
||||||
return self.playlist_result(entries, channel_id)
|
return self.playlist_result(entries, channel_id)
|
||||||
|
|
||||||
def _entries():
|
def _entries():
|
||||||
more_widget_html = content_html = channel_page
|
more_widget_html = content_html = channel_page
|
||||||
for pagenum in itertools.count(1):
|
for pagenum in itertools.count(1):
|
||||||
|
|
||||||
ids_in_page = self.extract_videos_from_page(content_html)
|
for video_id, video_title in self.extract_videos_from_page(content_html):
|
||||||
for video_id, video_title in ids_in_page:
|
|
||||||
yield self.url_result(
|
yield self.url_result(
|
||||||
video_id, 'Youtube', video_id=video_id,
|
video_id, 'Youtube', video_id=video_id,
|
||||||
video_title=video_title)
|
video_title=video_title)
|
||||||
|
|
Loading…
Reference in a new issue