Skip to content

Commit 877bc23

Browse files
committed
refac
1 parent 0ad448b commit 877bc23

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

backend/open_webui/utils/middleware.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2884,7 +2884,7 @@ async def background_tasks_handler(ctx):
28842884
}
28852885
)
28862886

2887-
if title == None and len(messages) == 2:
2887+
if title == None and len(messages) == 2 and (not messages_map or len(messages_map) <= 2):
28882888
title = messages[0].get('content', user_message)
28892889

28902890
Chats.update_chat_title_by_id(metadata['chat_id'], title)

0 commit comments

Comments
 (0)