[ie/youtube] Add membership data to comments

This commit is contained in:
biggestsonicfan 2024-10-22 13:45:04 -07:00
parent dd2e244469
commit 1bd38adbf6

View file

@ -3634,6 +3634,8 @@ def _extract_comment(self, entities, parent=None):
'author_thumbnail': ('author', 'avatarThumbnailUrl', {url_or_none}),
'author_is_uploader': ('author', 'isCreator', {bool}),
'author_is_verified': ('author', 'isVerified', {bool}),
'author_is_member': ('author', 'sponsorBadgeA11y', {str}),
'author_member_badge': ('author', 'sponsorBadgeUrl', {url_or_none}),
'author_url': ('author', 'channelCommand', 'innertubeCommand', (
('browseEndpoint', 'canonicalBaseUrl'), ('commandMetadata', 'webCommandMetadata', 'url'),
), {lambda x: urljoin('https://www.youtube.com', x)}),