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

[faz] Future-proof XML element check

Philipp Hagemeister 9 лет назад
Родитель
Сommit
9c86d50916
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      youtube_dl/extractor/faz.py

+ 1 - 1
youtube_dl/extractor/faz.py

@@ -52,7 +52,7 @@ class FazIE(InfoExtractor):
         formats = []
         for pref, code in enumerate(['LOW', 'HIGH', 'HQ']):
             encoding = xpath_element(encodings, code)
-            if encoding:
+            if encoding is not None:
                 encoding_url = xpath_text(encoding, 'FILENAME')
                 if encoding_url:
                     formats.append({