Upload 26 files
Browse files
app/components/chat/ApiKeyWarning.tsx
CHANGED
|
@@ -7,7 +7,7 @@ interface ApiKeyWarningProps {
|
|
| 7 |
}
|
| 8 |
|
| 9 |
export const ApiKeyWarning: React.FC<ApiKeyWarningProps> = ({ provider, apiKeys }) => {
|
| 10 |
-
const isApiKeyMissing = !apiKeys[provider
|
| 11 |
|
| 12 |
if (!isApiKeyMissing) return null;
|
| 13 |
|
|
|
|
| 7 |
}
|
| 8 |
|
| 9 |
export const ApiKeyWarning: React.FC<ApiKeyWarningProps> = ({ provider, apiKeys }) => {
|
| 10 |
+
const isApiKeyMissing = !apiKeys[provider?.name];
|
| 11 |
|
| 12 |
if (!isApiKeyMissing) return null;
|
| 13 |
|
app/components/chat/BaseChat.tsx
CHANGED
|
@@ -314,7 +314,7 @@ export const BaseChat = React.forwardRef<HTMLDivElement, BaseChatProps>(
|
|
| 314 |
}
|
| 315 |
};
|
| 316 |
|
| 317 |
-
const isApiKeyAvailable = apiKeys && apiKeys[provider
|
| 318 |
|
| 319 |
const baseChat = (
|
| 320 |
<div
|
|
|
|
| 314 |
}
|
| 315 |
};
|
| 316 |
|
| 317 |
+
const isApiKeyAvailable = apiKeys && apiKeys[provider?.name];
|
| 318 |
|
| 319 |
const baseChat = (
|
| 320 |
<div
|