mirror of
https://github.com/BerriAI/litellm.git
synced 2026-09-12 23:01:41 +00:00
fix: align fetchTools early-return guard with canFetchTools auth_type check for non-OpenAPI transports
This commit is contained in:
parent
e707a99c1a
commit
5584c92eff
1 changed files with 5 additions and 0 deletions
|
|
@ -79,6 +79,11 @@ export const useTestMCPConnection = ({
|
|||
return;
|
||||
}
|
||||
|
||||
// For non-OpenAPI transports, auth_type must be selected (mirrors the canFetchTools check).
|
||||
if (!isOpenAPITransport && !formValues.auth_type) {
|
||||
return;
|
||||
}
|
||||
|
||||
// For OpenAPI transport, tools are derived from the spec — no OAuth token needed.
|
||||
if (requiresOAuthToken && !oauthAccessToken && !isOpenAPITransport) {
|
||||
return;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue