channel: replace page #s w/ next page button using provided ctoken
Since yt doesn't accept page #'s when sorting by oldest Signed-off-by: Jesús <heckyel@hyperbola.info>
This commit is contained in:
@@ -66,6 +66,7 @@ def extract_channel_info(polymer_json, tab):
|
||||
|
||||
# get items
|
||||
info['items'] = []
|
||||
info['ctoken'] = None
|
||||
|
||||
# empty channel
|
||||
if 'contents' not in response and 'continuationContents' not in response:
|
||||
@@ -75,6 +76,7 @@ def extract_channel_info(polymer_json, tab):
|
||||
items, ctoken = extract_items(response)
|
||||
additional_info = {'author': info['channel_name'], 'author_url': info['channel_url']}
|
||||
info['items'] = [extract_item_info(renderer, additional_info) for renderer in items]
|
||||
info['ctoken'] = ctoken
|
||||
if tab == 'search':
|
||||
info['is_last_page'] = (ctoken is None)
|
||||
elif tab == 'about':
|
||||
|
||||
Reference in New Issue
Block a user