description bug fix
This commit is contained in:
parent
00e295aeb9
commit
dff2109685
@ -43,13 +43,16 @@ class Varzesh3IE(InfoExtractor):
|
|||||||
|
|
||||||
title = self._html_search_regex(r'meta[^>]+property="og:title"[^>]+content="([^"]+)"', webpage, 'title')
|
title = self._html_search_regex(r'meta[^>]+property="og:title"[^>]+content="([^"]+)"', webpage, 'title')
|
||||||
video_link = self._html_search_regex(r'source[^>]+src="([^"]+)"', webpage, 'video_link')
|
video_link = self._html_search_regex(r'source[^>]+src="([^"]+)"', webpage, 'video_link')
|
||||||
id = self._html_search_regex(r"link[^>]+rel='canonical'[^>]+href='\/\?p=([^']+)'\/>", webpage, 'id')
|
vid_id = self._html_search_regex(r"link[^>]+rel='canonical'[^>]+href='\/\?p=([^']+)'\/>", webpage, 'vid_id')
|
||||||
description = self._html_search_regex(r'<div[^>]+class="matn">[^<]+<p>([^<]+)<\/p>', webpage, 'description')
|
try:
|
||||||
|
description = self._html_search_regex(r'<div class="matn">(.*?)</div>', webpage, 'description')
|
||||||
|
except:
|
||||||
|
description = title
|
||||||
thumbnail = self._html_search_regex(r'link[^>]+rel="image_src"[^>]+href="([^"]+)"', webpage, 'thumbnail')
|
thumbnail = self._html_search_regex(r'link[^>]+rel="image_src"[^>]+href="([^"]+)"', webpage, 'thumbnail')
|
||||||
|
|
||||||
return {
|
return {
|
||||||
'url': video_link,
|
'url': video_link,
|
||||||
'id': id,
|
'id': vid_id,
|
||||||
'title': title,
|
'title': title,
|
||||||
'ext': video_link.split(".")[-1],
|
'ext': video_link.split(".")[-1],
|
||||||
'description': description,
|
'description': description,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user