From 98a62d7cbd57c546871eb47460efc5eb95aec874 Mon Sep 17 00:00:00 2001 From: Remita Amine Date: Fri, 11 Dec 2020 21:50:40 +0100 Subject: [PATCH] [facebook] Add another regex for handleServerJS --- youtube_dl/extractor/facebook.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/youtube_dl/extractor/facebook.py b/youtube_dl/extractor/facebook.py index bc4844adc..cc45aacc0 100644 --- a/youtube_dl/extractor/facebook.py +++ b/youtube_dl/extractor/facebook.py @@ -365,8 +365,8 @@ class FacebookIE(InfoExtractor): return video_data server_js_data = self._parse_json(self._search_regex( - r'handleServerJS\(({.+})(?:\);|,")', webpage, - 'server js data', default='{}'), video_id, fatal=False) + [r'handleServerJS\(({.+})(?:\);|,")', r'\bs\.handle\(({.+?})\);'], + webpage, 'server js data', default='{}'), video_id, fatal=False) if server_js_data: video_data = extract_video_data(server_js_data.get('instances', [])) -- 2.22.2