mirror of
https://github.com/open-webui/open-webui.git
synced 2026-10-18 04:43:55 +00:00
fix: message in a chat opened from the sidebar fails with "is not valid JSON" (#32534)
Opening a chat from the sidebar while the home page was still setting up a new chat let that setup finish afterwards and clear the opened chat's id. The next message then failed with "Unexpected token 'd', "data: {"id"... is not valid JSON" and the chat's tags did not load. The new chat setup now stops once another chat has been opened. Signing in to an OAuth tool still turns it on together with the model's default tools.
Follow-up to #32488
This commit is contained in:
parent
51a4d58270
commit
aa1dd240cd
1 changed files with 3 additions and 0 deletions
|
|
@ -2751,7 +2751,10 @@
|
|||
|
||||
// resetInput() must stay last: the selected model's defaults override the draft's selection.
|
||||
await restoreChatInput(sessionStorage.getItem('chat-input'));
|
||||
const previousChatId = $chatId;
|
||||
await resetInput();
|
||||
// A chat opened in the meantime keeps its id
|
||||
if ($chatId !== previousChatId) return;
|
||||
await chatId.set('');
|
||||
await chatTitle.set('');
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue