From 0f3bfa280a385ae76844900109fdc88d41d9f7f1 Mon Sep 17 00:00:00 2001 From: heheer Date: Tue, 20 May 2025 20:21:00 +0800 Subject: [PATCH] fix quote reader duplicate rendering (#4845) --- .../pageComponents/chat/ChatQuoteList/index.tsx | 17 +++++++---------- 1 file changed, 7 insertions(+), 10 deletions(-) diff --git a/projects/app/src/pageComponents/chat/ChatQuoteList/index.tsx b/projects/app/src/pageComponents/chat/ChatQuoteList/index.tsx index 657b9f0ae..6d05fac7a 100644 --- a/projects/app/src/pageComponents/chat/ChatQuoteList/index.tsx +++ b/projects/app/src/pageComponents/chat/ChatQuoteList/index.tsx @@ -13,16 +13,13 @@ const ChatQuoteList = ({ metadata: GetQuoteProps; onClose: () => void; }) => { - return ( - <> - {'collectionId' in metadata && ( - - )} - {'collectionIdList' in metadata && ( - - )} - - ); + if ('collectionId' in metadata) { + return ; + } else if ('collectionIdList' in metadata) { + return ; + } + + return null; }; export default ChatQuoteList;