Browse Source

[screencast] Improve extraction (closes #14617, closes #17990)

Sergey M․ 6 năm trước cách đây
mục cha
commit
a1d1c63678
1 tập tin đã thay đổi với 2 bổ sung1 xóa
  1. 2 1
      youtube_dl/extractor/screencast.py

+ 2 - 1
youtube_dl/extractor/screencast.py

@@ -92,7 +92,8 @@ class ScreencastIE(InfoExtractor):
 
         if video_url is None:
             video_url = self._html_search_regex(
-                r'"MediaContentUrl":"([^"]+)"', webpage, 'media content url', default=None)
+                r'MediaContentUrl["\']\s*:(["\'])(?P<url>(?:(?!\1).)+)\1',
+                webpage, 'video url', default=None, group='url')
 
         if video_url is None:
             video_url = self._html_search_meta(