Просмотр исходного кода

[infoq] Make audio format extraction non fatal (closes #12938)

Sergey M․ 8 лет назад
Родитель
Сommit
74da856544
1 измененных файлов с 2 добавлено и 2 удалено
  1. 2 2
      youtube_dl/extractor/infoq.py

+ 2 - 2
youtube_dl/extractor/infoq.py

@@ -87,8 +87,8 @@ class InfoQIE(BokeCCBaseIE):
 
 
     def _extract_http_audio(self, webpage, video_id):
     def _extract_http_audio(self, webpage, video_id):
         fields = self._hidden_inputs(webpage)
         fields = self._hidden_inputs(webpage)
-        http_audio_url = fields['filename']
-        if http_audio_url is None:
+        http_audio_url = fields.get('filename')
+        if not http_audio_url:
             return []
             return []
 
 
         cookies_header = {'Cookie': self._extract_cookies(webpage)}
         cookies_header = {'Cookie': self._extract_cookies(webpage)}