Fixed clear chat

This commit is contained in:
jeffser
2024-09-11 10:51:04 -06:00
parent 80dcae194b
commit 51d2326dee
3 changed files with 5 additions and 4 deletions

View File

@@ -562,7 +562,7 @@ Generate a title following these rules:
def save_history(self, chat:chat_widget.chat=None):
logger.debug("Saving history")
logger.info("Saving history")
history = None
if chat and os.path.exists(os.path.join(data_dir, "chats", "chats.json")):
history = {'chats': {chat.get_name(): {'messages': chat.messages_to_dict()}}}