浏览代码

[hypestat] Match URLs with www. and https://

Philipp Hagemeister 11 年之前
父节点
当前提交
37bfe8ace4
共有 1 个文件被更改,包括 4 次插入1 次删除
  1. 4 1
      youtube_dl/extractor/hypestat.py

+ 4 - 1
youtube_dl/extractor/hypestat.py

@@ -13,7 +13,7 @@ from ..utils import (
 
 class HypestatIE(InfoExtractor):
     IE_DESC = 'allmyvideos.net and vidspot.net'
-    _VALID_URL = r'https?://(?:allmyvideos|vidspot)\.net/(?P<id>[a-zA-Z0-9_-]+)'
+    _VALID_URL = r'https?://(?:www\.)?(?:allmyvideos|vidspot)\.net/(?P<id>[a-zA-Z0-9_-]+)'
 
     _TESTS = [{
         'url': 'http://allmyvideos.net/jih3nce3x6wn',
@@ -31,6 +31,9 @@ class HypestatIE(InfoExtractor):
             'ext': 'mp4',
             'title': 'youtube-dl test video',
         },
+    }, {
+        'url': 'https://www.vidspot.net/l2ngsmhs8ci5',
+        'only_matching': True,
     }]
 
     def _real_extract(self, url):