diff --git a/ui/litellm-dashboard/src/components/chat_ui.tsx b/ui/litellm-dashboard/src/components/chat_ui.tsx index 5b23ec11e3c..7f2b0e1a263 100644 --- a/ui/litellm-dashboard/src/components/chat_ui.tsx +++ b/ui/litellm-dashboard/src/components/chat_ui.tsx @@ -86,6 +86,10 @@ const ChatUI: React.FC = ({ // Fetch model info and set the default selected model const loadModels = async () => { try { + if (!userApiKey) { + console.log("userApiKey is missing"); + return; + } const uniqueModels = await fetchAvailableModels( userApiKey, );