TheHamkerCat 5 년 전
부모
커밋
3e2acf2117
2개의 변경된 파일과 2개의 추가작업 그리고 2개의 파일을 삭제
  1. 1 1
      wbb/modules/arq_storage.py
  2. 1 1
      wbb/utils/functions.py

+ 1 - 1
wbb/modules/arq_storage.py

@@ -80,7 +80,7 @@ async def arq_upload(_, message):
         async with UPLOAD_LOCK:
             r = message.reply_to_message
 
-            file_id = get_file_id_from_message(r, 100000000, [])
+            file_id = get_file_id_from_message(r, 100000000, None)
             if not file_id:
                 return await message.reply("Unsupported media.")
 

+ 1 - 1
wbb/utils/functions.py

@@ -251,7 +251,7 @@ def get_file_id_from_message(
 
         mime_type = message.document.mime_type
 
-        if mime_type not in mime_types:
+        if mime_types and mime_type not in mime_types:
             return
         file_id = message.document.file_id