Browse Source

fix: merge conflict between #11301 and #11885 (#13391)

Hash Brown 2 months ago
parent
commit
78708eb5d5
1 changed files with 6 additions and 7 deletions
  1. 6 7
      web/app/components/workflow/panel/debug-and-preview/hooks.ts

+ 6 - 7
web/app/components/workflow/panel/debug-and-preview/hooks.ts

@@ -425,13 +425,12 @@ export const useChat = (
           else
             responseItem.workflowProcess!.tracing[currentIndex].retryDetail = [data as NodeTracing]
 
-          handleUpdateChatList(produce(chatListRef.current, (draft) => {
-            const currentIndex = draft.findIndex(item => item.id === responseItem.id)
-            draft[currentIndex] = {
-              ...draft[currentIndex],
-              ...responseItem,
-            }
-          }))
+          updateCurrentQAOnTree({
+            placeholderQuestionId,
+            questionItem,
+            responseItem,
+            parentId: params.parent_message_id,
+          })
         },
         onNodeFinished: ({ data }) => {
           if (data.iteration_id)