瀏覽代碼

Update files.py

fix formatting
jmtatsch 5 月之前
父節點
當前提交
056a042ef2
共有 1 個文件被更改,包括 9 次插入1 次删除
  1. 9 1
      backend/open_webui/routers/files.py

+ 9 - 1
backend/open_webui/routers/files.py

@@ -129,7 +129,15 @@ def upload_file(
                         ProcessFileForm(file_id=id, content=result.get("text", "")),
                         user=user,
                     )
-                elif file.content_type not in ["image/png", "image/jpeg", "image/gif", "video/mp4", "video/ogg", "video/quicktime", "video/webm"]:
+                elif file.content_type not in [
+                    "image/png",
+                    "image/jpeg",
+                    "image/gif",
+                    "video/mp4",
+                    "video/ogg",
+                    "video/quicktime",
+                    "video/webm",
+                ]:
                     process_file(request, ProcessFileForm(file_id=id), user=user)
 
                 file_item = Files.get_file_by_id(id=id)