From 44966db50571567af2897c48fd859cec958d178d Mon Sep 17 00:00:00 2001 From: Michael Poluektov Date: Mon, 19 Aug 2024 17:04:57 +0100 Subject: [PATCH] avoid ugly exception --- backend/main.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backend/main.py b/backend/main.py index 461ae937b..3e3d265a2 100644 --- a/backend/main.py +++ b/backend/main.py @@ -414,7 +414,7 @@ async def chat_completion_tools_handler( content = await get_content_from_response(response) log.debug(f"{content=}") - if content is None: + if not content: return body, {} result = json.loads(content)