浏览代码

[brightcove:new] Add ability to smuggle geo_countries into URL

Sergey M․ 8 年之前
父节点
当前提交
d16f27ca27
共有 1 个文件被更改,包括 3 次插入0 次删除
  1. 3 0
      youtube_dl/extractor/brightcove.py

+ 3 - 0
youtube_dl/extractor/brightcove.py

@@ -515,6 +515,9 @@ class BrightcoveNewIE(InfoExtractor):
         return entries
 
     def _real_extract(self, url):
+        url, smuggled_data = unsmuggle_url(url, {})
+        self._initialize_geo_bypass(smuggled_data.get('geo_countries'))
+
         account_id, player_id, embed, video_id = re.match(self._VALID_URL, url).groups()
 
         webpage = self._download_webpage(