X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=blobdiff_plain;f=youtube_dl%2Fextractor%2Fir90tv.py;h=214bcd5b59c1a95a7a34ebc2acd87b2dc6f76454;hb=e8bcd982ccee87e45a5cc8b116cc4452c81b0453;hp=880a6e32f6b4b9ea6a683c25238f8953a8355030;hpb=eab7faa0c1e8511bc91c64347d0dffc28c94f101;p=youtube-dl diff --git a/youtube_dl/extractor/ir90tv.py b/youtube_dl/extractor/ir90tv.py index 880a6e32f..214bcd5b5 100644 --- a/youtube_dl/extractor/ir90tv.py +++ b/youtube_dl/extractor/ir90tv.py @@ -2,6 +2,7 @@ from __future__ import unicode_literals from .common import InfoExtractor +from ..utils import remove_start class Ir90TvIE(InfoExtractor): @@ -24,18 +25,18 @@ class Ir90TvIE(InfoExtractor): video_id = self._match_id(url) webpage = self._download_webpage(url, video_id) - title = self._html_search_regex( - r'\n90tv.ir :: (.*?)', webpage, 'title') + title = remove_start(self._html_search_regex( + r'([^<]+)', webpage, 'title'), '90tv.ir :: ') video_url = self._search_regex( r']+src="([^"]+)"', webpage, 'video url') - thumbnail = self._search_regex(r'poster="([^"]+)"', webpage, 'thumbnail url') + thumbnail = self._search_regex(r'poster="([^"]+)"', webpage, 'thumbnail url', fatal=False) return { 'url': video_url, 'id': video_id, 'title': title, - 'video_url' : video_url, - 'thumbnail' : thumbnail, + 'video_url': video_url, + 'thumbnail': thumbnail, }