diff --git a/src/components/Layout.tsx b/src/components/Layout.tsx index c12a604..f3bfeba 100644 --- a/src/components/Layout.tsx +++ b/src/components/Layout.tsx @@ -99,6 +99,8 @@ export function Layout() { if (chatId) { dataFetch(); + } else { + setChat(null); } }, [chatId]); diff --git a/src/routes/IndexRoute.tsx b/src/routes/IndexRoute.tsx index 15c24bd..b8aa2ba 100644 --- a/src/routes/IndexRoute.tsx +++ b/src/routes/IndexRoute.tsx @@ -23,7 +23,7 @@ export function IndexRoute() { <>