From c04e408432b24e2a6cbeb2eaf513b8f2840460b6 Mon Sep 17 00:00:00 2001 From: G30 <50341825+silentoplayz@users.noreply.github.com> Date: Sat, 24 Oct 2026 01:30:06 -0400 Subject: [PATCH] fix: deleting the open chat from the sidebar leaves its messages on screen (#33069) --- src/lib/components/chat/Chat.svelte | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib/components/chat/Chat.svelte b/src/lib/components/chat/Chat.svelte index d2df48cbd5..c8749c0b96 100644 --- a/src/lib/components/chat/Chat.svelte +++ b/src/lib/components/chat/Chat.svelte @@ -2767,7 +2767,7 @@ const previousMessageId = history.currentId; await resetInput(); // A chat opened or a message sent in the meantime keeps its id and history - if ($chatId !== previousChatId || history.currentId !== previousMessageId) return; + if (($chatId && $chatId !== previousChatId) || history.currentId !== previousMessageId) return; await chatId.set(''); await chatTitle.set('');