From 00bb64d553275503673874756f7c89ca94005ba0 Mon Sep 17 00:00:00 2001 From: Nicolas Zeeb Date: Tue, 24 Feb 2026 17:00:13 -0500 Subject: [PATCH] fix: validate conversation exists before renaming in handleSessionRename Co-Authored-By: Claude --- assistant/src/daemon/handlers/sessions.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/assistant/src/daemon/handlers/sessions.ts b/assistant/src/daemon/handlers/sessions.ts index 4441b8f6cb5..f3b55c0dfbe 100644 --- a/assistant/src/daemon/handlers/sessions.ts +++ b/assistant/src/daemon/handlers/sessions.ts @@ -358,6 +358,11 @@ export function handleSessionRename( socket: net.Socket, ctx: HandlerContext, ): void { + const conversation = conversationStore.getConversation(msg.sessionId); + if (!conversation) { + ctx.send(socket, { type: 'error', message: `Session ${msg.sessionId} not found` }); + return; + } conversationStore.updateConversationTitle(msg.sessionId, msg.title); ctx.send(socket, { type: 'session_title_updated',