Fix: When I click to interrupt the chat, the page reports an error #10553 (#10554)

### What problem does this PR solve?
Fix: When I click to interrupt the chat, the page reports an error
#10553

### Type of change

- [x] Bug Fix (non-breaking change which fixes an issue)
This commit is contained in:
balibabu
2025-10-14 19:07:18 +08:00
committed by GitHub
parent 51139de178
commit 960f47c4d4
6 changed files with 20 additions and 21 deletions

View File

@ -123,10 +123,6 @@ export const useSendMessage = (controller: AbortController) => {
[getConversationIsNew, handleUploadFile, setConversation],
);
const stopOutputMessage = useCallback(() => {
controller.abort();
}, [controller]);
const sendMessage = useCallback(
async ({
message,
@ -249,7 +245,6 @@ export const useSendMessage = (controller: AbortController) => {
messageContainerRef,
derivedMessages,
removeMessageById,
stopOutputMessage,
handleUploadFile: onUploadFile,
isUploading,
removeFile,