From 11f93a88004228d4977c36b3830fed83457ef1af Mon Sep 17 00:00:00 2001 From: Anirban Kar Date: Sun, 8 Dec 2024 04:12:29 +0530 Subject: [PATCH] Update ImportFolderButton.tsx added fix --- app/components/chat/ImportFolderButton.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/components/chat/ImportFolderButton.tsx b/app/components/chat/ImportFolderButton.tsx index 70e9f1f4..e766a716 100644 --- a/app/components/chat/ImportFolderButton.tsx +++ b/app/components/chat/ImportFolderButton.tsx @@ -54,10 +54,10 @@ export const ImportFolderButton: React.FC = ({ classNam toast.info(`Skipping ${binaryFilePaths.length} binary files`); } - const { userMessage, assistantMessage } = await createChatFromFolder(textFiles, binaryFilePaths, folderName); + const messages = await createChatFromFolder(textFiles, binaryFilePaths, folderName); if (importChat) { - await importChat(folderName, [userMessage, assistantMessage]); + await importChat(folderName, [...messages]); } toast.success('Folder imported successfully');