From 59d2358845426223d64f19a74a846899e0da2288 Mon Sep 17 00:00:00 2001 From: James Blair Date: Fri, 8 May 2026 20:34:18 +1200 Subject: [PATCH] Check if error exists in Chat rather than ChatError --- components/chat/chat-error.tsx | 4 +--- components/chat/index.tsx | 2 +- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/components/chat/chat-error.tsx b/components/chat/chat-error.tsx index a9edcf4..3a25923 100644 --- a/components/chat/chat-error.tsx +++ b/components/chat/chat-error.tsx @@ -1,9 +1,7 @@ import { AlertTriangleIcon } from "lucide-react"; import { Alert, AlertDescription, AlertTitle } from "../ui/alert"; -export function ChatError({ error }: { error?: Error }) { - if (!error) return null; - +export function ChatError({ error }: { error: Error }) { return ( diff --git a/components/chat/index.tsx b/components/chat/index.tsx index 566c38d..b0016df 100644 --- a/components/chat/index.tsx +++ b/components/chat/index.tsx @@ -15,7 +15,7 @@ export function Chat() { return (
- + {error && }