From: Sergey M․ Date: Fri, 27 Sep 2019 17:04:52 +0000 (+0700) Subject: [vk] Fix extraction (closes #22522) X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=commitdiff_plain;h=6483fbd336839c45a376d08d8f4a34e97d581e5e;p=youtube-dl [vk] Fix extraction (closes #22522) --- diff --git a/youtube_dl/extractor/vk.py b/youtube_dl/extractor/vk.py index f57ed2288..8b6dc0e24 100644 --- a/youtube_dl/extractor/vk.py +++ b/youtube_dl/extractor/vk.py @@ -403,8 +403,17 @@ class VKIE(VKBaseIE): data = self._parse_json( self._search_regex( r'var\s+playerParams\s*=\s*({.+?})\s*;\s*\n', info_page, - 'player params'), - video_id)['params'][0] + 'player params', default='{}'), + video_id) + if data: + data = data['params'][0] + + #