From bfc85f8a49ee1eec0cf743664c3741d3303a7632 Mon Sep 17 00:00:00 2001 From: Mort Yao Date: Fri, 18 Oct 2013 23:03:56 +0200 Subject: [PATCH] Miomio: add Sina as video source --- src/you_get/extractor/miomio.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/you_get/extractor/miomio.py b/src/you_get/extractor/miomio.py index cbdad765..bac1f64c 100644 --- a/src/you_get/extractor/miomio.py +++ b/src/you_get/extractor/miomio.py @@ -4,6 +4,7 @@ __all__ = ['miomio_download'] from ..common import * +from .sina import sina_download_by_vid from .tudou import tudou_download_by_id from .youku import youku_download_by_id @@ -16,9 +17,11 @@ def miomio_download(url, output_dir = '.', merge = True, info_only = False): t = r1(r'type=(\w+)', flashvars) id = r1(r'vid=([^"]+)', flashvars) if t == 'youku': - youku_download_by_id(id, title, output_dir = output_dir, merge = merge, info_only = info_only) + youku_download_by_id(id, title, output_dir=output_dir, merge=merge, info_only=info_only) elif t == 'tudou': - tudou_download_by_id(id, title, output_dir = output_dir, merge = merge, info_only = info_only) + tudou_download_by_id(id, title, output_dir=output_dir, merge=merge, info_only=info_only) + elif t == 'sina': + sina_download_by_vid(id, title, output_dir=output_dir, merge=merge, info_only=info_only) else: raise NotImplementedError(flashvars)