refactor: improve tool call result handling and display in conversation components

This commit is contained in:
Siddhant Rai
2025-06-11 19:28:15 +05:30
parent aaecf52c99
commit 9b839655a7
4 changed files with 27 additions and 15 deletions

View File

@@ -293,10 +293,11 @@ export const conversationSlice = createSlice({
);
if (existingIndex !== -1) {
Object.assign(
state.queries[index].tool_calls[existingIndex],
tool_call,
);
const existingCall = state.queries[index].tool_calls[existingIndex];
state.queries[index].tool_calls[existingIndex] = {
...existingCall,
...tool_call,
};
} else state.queries[index].tool_calls.push(tool_call);
},
updateQuery(