mirror of
https://github.com/diegosouzapw/OmniRoute.git
synced 2026-08-20 06:02:14 +03:00
style(sse): condense flag-removal NOTE comment (review feedback)
Compresses the explanatory NOTE in claudeCodeToolRemapper.ts from 6 lines to 4 while keeping the actionable why: the flag has no readers, would leak into the Anthropic request body causing HTTP 400 (Extra inputs are not permitted), and the response-side remap is unconditional. Addresses gemini-code-assist review feedback on PR #2290.
This commit is contained in:
@@ -88,12 +88,10 @@ export function remapToolNamesInRequest(body: Record<string, unknown>): boolean
|
||||
}
|
||||
}
|
||||
|
||||
// NOTE: previously set body._claudeCodeRequiresLowercaseToolNames = true here.
|
||||
// Removed: the flag had no readers in the codebase and leaked into the
|
||||
// outgoing Anthropic request body, causing HTTP 400
|
||||
// "_claudeCodeRequiresLowercaseToolNames: Extra inputs are not permitted".
|
||||
// The response-side lowercase remap is unconditional anyway via
|
||||
// remapToolNamesInResponse(text, forceLowercase=true).
|
||||
// NOTE: do not set body._claudeCodeRequiresLowercaseToolNames here.
|
||||
// The flag has no readers and would leak into the outgoing Anthropic
|
||||
// request body, causing HTTP 400 (Extra inputs are not permitted).
|
||||
// The response-side remap is unconditional via remapToolNamesInResponse.
|
||||
|
||||
return hasLowercase && !hasTitleCase;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user