fix: resolve golangci-lint error - rename shadowed 'max' parameter to 'maxRedirects'

This commit is contained in:
GitHub Actions
2025-12-23 15:07:37 +00:00
parent 6206492c65
commit 7c6410ff97
+2 -2
View File
@@ -36,8 +36,8 @@ func WithTimeout(timeout time.Duration) ValidationOption {
}
// WithMaxRedirects sets the maximum number of redirects to follow (default: 0).
func WithMaxRedirects(max int) ValidationOption {
return func(c *ValidationConfig) { c.MaxRedirects = max }
func WithMaxRedirects(maxRedirects int) ValidationOption {
return func(c *ValidationConfig) { c.MaxRedirects = maxRedirects }
}
// ValidateExternalURL validates a URL for external HTTP requests with comprehensive SSRF protection.