about summary refs log tree commit diff
path: root/youtube_dl/extractor/mlb.py
diff options
context:
space:
mode:
authorSergey M․ <dstftw@gmail.com>2015-03-23 21:23:57 +0600
committerSergey M․ <dstftw@gmail.com>2015-03-23 21:23:57 +0600
commit9f790b9901445d532564b3c5c90c0ecfaea4805d (patch)
tree5b7d43ad17f0b17c8b0dd19cfef282243ec7cdc0 /youtube_dl/extractor/mlb.py
parent93f787070ff2de48023c5bfeaebd153b3e29137a (diff)
downloadyoutube-dl-9f790b9901445d532564b3c5c90c0ecfaea4805d.tar.gz
youtube-dl-9f790b9901445d532564b3c5c90c0ecfaea4805d.tar.xz
youtube-dl-9f790b9901445d532564b3c5c90c0ecfaea4805d.zip
[mlb] Improve _VALID_URL (Closes #5260)
Diffstat (limited to 'youtube_dl/extractor/mlb.py')
-rw-r--r--youtube_dl/extractor/mlb.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/youtube_dl/extractor/mlb.py b/youtube_dl/extractor/mlb.py
index 1a241aca7..e369551c2 100644
--- a/youtube_dl/extractor/mlb.py
+++ b/youtube_dl/extractor/mlb.py
@@ -10,7 +10,7 @@ from ..utils import (
 
 
 class MLBIE(InfoExtractor):
-    _VALID_URL = r'https?://m(?:lb)?\.mlb\.com/(?:(?:.*?/)?video/(?:topic/[\da-z_-]+/)?v|(?:shared/video/embed/embed\.html|[^/]+/video/play\.jsp)\?.*?\bcontent_id=)(?P<id>n?\d+)'
+    _VALID_URL = r'https?://m(?:lb)?\.(?:[\da-z_-]+\.)?mlb\.com/(?:(?:.*?/)?video/(?:topic/[\da-z_-]+/)?v|(?:shared/video/embed/embed\.html|[^/]+/video/play\.jsp)\?.*?\bcontent_id=)(?P<id>n?\d+)'
     _TESTS = [
         {
             'url': 'http://m.mlb.com/sea/video/topic/51231442/v34698933/nymsea-ackley-robs-a-home-run-with-an-amazing-catch/?c_id=sea',
@@ -80,6 +80,10 @@ class MLBIE(InfoExtractor):
             'url': 'http://mlb.mlb.com/es/video/play.jsp?content_id=36599553',
             'only_matching': True,
         },
+        {
+            'url': 'http://m.cardinals.mlb.com/stl/video/v51175783/atlstl-piscotty-makes-great-sliding-catch-on-line/?partnerId=as_mlb_20150321_42500876&adbid=579409712979910656&adbpl=tw&adbpr=52847728',
+            'only_matching': True,
+        }
     ]
 
     def _real_extract(self, url):