Merge pull request #331 from aviperes/facebook_videos_new_ui_bug_fix

fix title, subscription, comments, live
This commit is contained in:
aviperetz34 2020-06-07 15:43:26 +03:00 committed by GitHub
commit ea45fd1032
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -507,9 +507,10 @@ class FacebookIE(InfoExtractor):
def get_from_new_ui(self, webpage, tahoe_data, url):
video_title = self._search_regex(r'"headline":"(.+?")', webpage, 'title')
comments_count = parse_count(self._search_regex(r'"commentCount":(.+?,)', webpage, 'comments_count'))
subtitles = self._search_regex(r'"about":"(.+?")', webpage, 'subtitles')
video_title = self._search_regex(r'"headline":"(.+?")', webpage, 'title', fatal=False)
if not video_title:
video_title = self._search_regex(r'"pageTitle">(.+?)<', webpage, 'title')
comments_count = parse_count(self._search_regex(r'"commentCount":(.+?,)', webpage, 'comments_count', fatal=False))
likes = parse_count(self._extract_likes(webpage, tahoe_data))
timestamp = self._search_regex(r'"datePublished":"(.+?)"', webpage, 'timestamp')