mirror of
https://github.com/open-webui/open-webui
synced 2024-11-24 21:13:59 +00:00
refac
This commit is contained in:
parent
180f2b9a83
commit
4a21c5c5e7
@ -278,7 +278,11 @@ async def generate_function_chat_completion(form_data, user):
|
|||||||
model_info = Models.get_model_by_id(model_id)
|
model_info = Models.get_model_by_id(model_id)
|
||||||
metadata = form_data.pop("metadata", {})
|
metadata = form_data.pop("metadata", {})
|
||||||
files = metadata.get("files", [])
|
files = metadata.get("files", [])
|
||||||
tool_ids = metadata.get("tool_ids") if metadata.get("tool_ids") else []
|
tool_ids = metadata.get("tool_ids", [])
|
||||||
|
|
||||||
|
# Check if tool_ids is None
|
||||||
|
if tool_ids is None:
|
||||||
|
tool_ids = []
|
||||||
|
|
||||||
__event_emitter__ = None
|
__event_emitter__ = None
|
||||||
__event_call__ = None
|
__event_call__ = None
|
||||||
|
Loading…
Reference in New Issue
Block a user