fix: 修复流水线golangci-lint 的 errcheck

This commit is contained in:
CoolCoolTomato
2026-03-11 22:56:20 +08:00
parent fd8ccaf01a
commit eb0b77bf4d

View File

@@ -1761,11 +1761,9 @@ func (s *OpenAIGatewayService) Forward(ctx context.Context, c *gin.Context, acco
// 移除 gpt-5.2-codex 以下的版本 verbosity 参数
// 确保高版本模型向低版本模型映射不报错
if !SupportsVerbosity(reqBody["model"].(string)) {
if !SupportsVerbosity(normalizedModel) {
if text, ok := reqBody["text"].(map[string]any); ok {
if _, ok := text["verbosity"].(string); ok {
delete(text, "verbosity")
}
delete(text, "verbosity")
}
}
}