1
0
Fork 0
mirror of https://codeberg.org/polarisfm/youtube-dl.git synced 2024-12-27 01:56:52 +00:00

[vk] avoid built-in names

This commit is contained in:
Philipp Hagemeister 2014-01-21 17:29:04 +01:00
parent 032b3df5af
commit 608bf69880

View file

@ -33,13 +33,13 @@ class VKIE(InfoExtractor):
if m_yt is not None: if m_yt is not None:
self.to_screen(u'Youtube video detected') self.to_screen(u'Youtube video detected')
return self.url_result(m_yt.group(1), 'Youtube') return self.url_result(m_yt.group(1), 'Youtube')
vars_json = self._search_regex(r'var vars = ({.*?});', info_page, u'vars') data_json = self._search_regex(r'var vars = ({.*?});', info_page, u'vars')
vars = json.loads(vars_json) data = json.loads(data_json)
return { return {
'id': compat_str(vars['vid']), 'id': compat_str(data['vid']),
'url': vars['url240'], 'url': data['url240'],
'title': unescapeHTML(vars['md_title']), 'title': unescapeHTML(data['md_title']),
'thumbnail': vars['jpg'], 'thumbnail': data['jpg'],
'uploader': vars['md_author'], 'uploader': data['md_author'],
} }