mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2024-12-03 11:56:40 +00:00
parent
fb47597b09
commit
7f4173ae7c
|
@ -7,6 +7,7 @@
|
||||||
from ..utils import (
|
from ..utils import (
|
||||||
ExtractorError,
|
ExtractorError,
|
||||||
HEADRequest,
|
HEADRequest,
|
||||||
|
parse_count,
|
||||||
str_to_int,
|
str_to_int,
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@ -85,8 +86,8 @@ def _real_extract(self, url):
|
||||||
uploader_id = self._search_regex(
|
uploader_id = self._search_regex(
|
||||||
r'\s+"profile": "([^"]+)",', webpage, 'uploader id', fatal=False)
|
r'\s+"profile": "([^"]+)",', webpage, 'uploader id', fatal=False)
|
||||||
description = self._og_search_description(webpage)
|
description = self._og_search_description(webpage)
|
||||||
like_count = str_to_int(self._search_regex(
|
like_count = parse_count(self._search_regex(
|
||||||
r'\bbutton-favorite\b[^>]+m-ajax-toggle-count="([^"]+)"',
|
r'\bbutton-favorite[^>]+>.*?<span[^>]+class=["\']toggle-number[^>]+>\s*([^<]+)',
|
||||||
webpage, 'like count', fatal=False))
|
webpage, 'like count', fatal=False))
|
||||||
view_count = str_to_int(self._search_regex(
|
view_count = str_to_int(self._search_regex(
|
||||||
[r'<meta itemprop="interactionCount" content="UserPlays:([0-9]+)"',
|
[r'<meta itemprop="interactionCount" content="UserPlays:([0-9]+)"',
|
||||||
|
|
Loading…
Reference in a new issue