fix: resolve remaining lint errors for upstream CI

- Fix errcheck: brave.go resp.Body.Close, manager_test.go Encode
- Fix gofmt: payment_config_service.go
- Fix unused: use shouldFallbackGeminiModel (with modelName param) in handler
This commit is contained in:
erio
2026-04-14 12:19:44 +08:00
parent 6a08efeef9
commit e8ee400a3f
4 changed files with 21 additions and 21 deletions

View File

@@ -62,7 +62,7 @@ func (b *BraveProvider) Search(ctx context.Context, req SearchRequest) (*SearchR
if err != nil {
return nil, fmt.Errorf("brave: request failed: %w", err)
}
defer resp.Body.Close()
defer func() { _ = resp.Body.Close() }()
body, err := io.ReadAll(io.LimitReader(resp.Body, maxResponseSize))
if err != nil {