mirror of https://github.com/langgenius/dify.git
fix(web): use isFirstMessage instead of hardcoded false for invalid data
The onData callback's second parameter is isFirstMessage, not isError. When encountering invalid response data (null or non-object), we should preserve the current isFirstMessage state rather than hardcoding false. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
parent
e1854b657e
commit
1c8a9491d8
|
|
@ -218,7 +218,7 @@ export const handleStream = (
|
|||
return
|
||||
}
|
||||
if (!bufferObj || typeof bufferObj !== 'object') {
|
||||
onData('', false, {
|
||||
onData('', isFirstMessage, {
|
||||
conversationId: undefined,
|
||||
messageId: '',
|
||||
errorMessage: 'Invalid response data',
|
||||
|
|
|
|||
Loading…
Reference in New Issue