From cbc4cf59478b93e1285f54908f773a150ef9bbb1 Mon Sep 17 00:00:00 2001 From: Saurabh Prakash Date: Tue, 9 Dec 2025 12:08:34 +0530 Subject: [PATCH] Refactor(chat): Remove multiple return statements in NewChatPage --- app/(chat)/page.tsx | 20 ++------------------ 1 file changed, 2 insertions(+), 18 deletions(-) diff --git a/app/(chat)/page.tsx b/app/(chat)/page.tsx index abb7e5fc20..b134d7c177 100644 --- a/app/(chat)/page.tsx +++ b/app/(chat)/page.tsx @@ -26,30 +26,14 @@ async function NewChatPage() { const cookieStore = await cookies(); const modelIdFromCookie = cookieStore.get("chat-model"); - - if (!modelIdFromCookie) { - return ( - <> - - - - ); - } + const initialChatModel = modelIdFromCookie?.value || DEFAULT_CHAT_MODEL; return ( <>