mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2024-11-25 16:51:26 +01:00
Compare commits
No commits in common. "0b7a1c3b5e04f368bfc278337801331c10576d10" and "7fa22268918388c374bc2ece1882c177c47125fa" have entirely different histories.
0b7a1c3b5e
...
7fa2226891
|
@ -4481,11 +4481,13 @@ class YoutubeIE(YoutubeBaseInfoExtractor):
|
||||||
info[mobj.group('type') + '_count'] = str_to_int(mobj.group('count'))
|
info[mobj.group('type') + '_count'] = str_to_int(mobj.group('count'))
|
||||||
break
|
break
|
||||||
|
|
||||||
info['like_count'] = traverse_obj(vpir, (
|
match = re.search(
|
||||||
'videoActions', 'menuRenderer', 'topLevelButtons', ...,
|
r'\b(\d+)\b',
|
||||||
'segmentedLikeDislikeButtonViewModel', 'likeButtonViewModel',
|
vpir['videoActions']['menuRenderer']['topLevelButtons'][0]
|
||||||
'likeButtonViewModel', 'toggleButtonViewModel', 'toggleButtonViewModel',
|
['segmentedLikeDislikeButtonViewModel']['likeButtonViewModel']
|
||||||
'defaultButtonViewModel', 'buttonViewModel', 'accessibilityText', {parse_count}), get_all=False)
|
['likeButtonViewModel']['toggleButtonViewModel']['toggleButtonViewModel']
|
||||||
|
['defaultButtonViewModel']['buttonViewModel']['accessibilityText'])
|
||||||
|
info['like_count'] = str_to_int(match.group(1))
|
||||||
|
|
||||||
vcr = traverse_obj(vpir, ('viewCount', 'videoViewCountRenderer'))
|
vcr = traverse_obj(vpir, ('viewCount', 'videoViewCountRenderer'))
|
||||||
if vcr:
|
if vcr:
|
||||||
|
|
Loading…
Reference in New Issue
Block a user