From ad6fcf2557f80069780425d5cdf5a9b9fba2bb34 Mon Sep 17 00:00:00 2001 From: Mort Yao Date: Sun, 6 Mar 2016 03:44:49 +0100 Subject: [PATCH] [infoq] fix #957 --- src/you_get/extractors/infoq.py | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/src/you_get/extractors/infoq.py b/src/you_get/extractors/infoq.py index 8214b473..cf8b59e0 100644 --- a/src/you_get/extractors/infoq.py +++ b/src/you_get/extractors/infoq.py @@ -40,11 +40,9 @@ class Infoq(VideoExtractor): ] request.install_opener(opener) - self.streams = { - 'video' : { 'url': s }, - 'audio' : { 'url': mp3 }, - 'slides' : { 'url': pdf } - } + if s: self.streams['video'] = {'url': s } + if mp3: self.streams['audio'] = { 'url': mp3 } + if pdf: self.streams['slides'] = { 'url': pdf } def extract(self, **kwargs): for i in self.streams: