Procházet zdrojové kódy

Merge pull request #11079 from MeteorSkyOne/dev

fix: allow error returns None
Timothy Jaeryang Baek před 2 měsíci
rodič
revize
376fce273e
1 změnil soubory, kde provedl 1 přidání a 1 odebrání
  1. 1 1
      backend/open_webui/utils/chat.py

+ 1 - 1
backend/open_webui/utils/chat.py

@@ -149,7 +149,7 @@ async def generate_direct_chat_completion(
             }
         )
 
-        if "error" in res:
+        if "error" in res and res["error"]:
             raise Exception(res["error"])
 
         return res