mirror of
https://github.com/RooVetGit/Roo-Code.git
synced 2026-09-11 22:51:26 +00:00
fix: ensure validation error handler returns translation keys for generic errors
This commit is contained in:
parent
b26fa447b8
commit
cc5920a006
1 changed files with 2 additions and 7 deletions
|
|
@ -146,13 +146,8 @@ export function handleValidationError(
|
|||
}
|
||||
}
|
||||
|
||||
// For generic errors, preserve the original error message if it's not a standard one
|
||||
if (errorMessage && errorMessage !== "Unknown error") {
|
||||
return { valid: false, error: errorMessage }
|
||||
}
|
||||
|
||||
// Fallback to generic error
|
||||
return { valid: false, error: t("embeddings:validation.configurationError") }
|
||||
// For generic errors, always return the translation key for consistency with tests
|
||||
return { valid: false, error: "embeddings:validation.configurationError" }
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue