fix(auth): show gateway dialog for all authentication errors (#1227)

This commit is contained in:
josh 2025-09-21 12:40:35 +01:00 committed by GitHub
parent 1aff7d9868
commit 5a3f8cac02
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 50 additions and 8 deletions

View file

@ -110,7 +110,9 @@ export function Chat({
if (error instanceof ChatSDKError) {
// Check if it's a credit card error
if (
error.message?.includes('AI Gateway requires a valid credit card')
error.message?.includes('AI Gateway requires a valid credit card') ||
error.message?.includes('AI Gateway authentication failed') ||
error.message?.includes('No authentication provided')
) {
setShowCreditCardAlert(true);
} else {