Browse Source

removed formats without audio

Hodza Alban 6 years ago
parent
commit
407cbdf7a6
1 changed files with 3 additions and 1 deletions
  1. 3 1
      main.py

+ 3 - 1
main.py

@@ -50,8 +50,10 @@ def get_format(bot, update):
         while True: # save the formats in the formats list
             try:
                 line = next(it)
-                if not line: # the last line is empty...
+                if not line: # the last line usually is empty...
                     raise StopIteration
+                if "video only" in line: # video without audio... why?
+                    continue
             except StopIteration:
                 break
             else: