Skip to content

Commit

Permalink
[mgtv] add url patterns
Browse files Browse the repository at this point in the history
  • Loading branch information
rosynirvana committed Mar 12, 2017
1 parent 96398d8 commit 3adc839
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/you_get/extractors/mgtv.py
Expand Up @@ -27,7 +27,10 @@ class MGTV(VideoExtractor):
def get_vid_from_url(url):
"""Extracts video ID from URL.
"""
return match1(url, 'http://www.mgtv.com/b/\d+/(\d+).html')
vid = match1(url, 'http://www.mgtv.com/b/\d+/(\d+).html')
if not vid:
vid = match1(url, 'http://www.mgtv.com/hz/bdpz/\d+/(\d+).html')
return vid

#----------------------------------------------------------------------
@staticmethod
Expand Down Expand Up @@ -150,4 +153,4 @@ def download(self, **kwargs):

site = MGTV()
download = site.download_by_url
download_playlist = site.download_playlist_by_url
download_playlist = site.download_playlist_by_url

0 comments on commit 3adc839

Please sign in to comment.