Skip to content

Commit

Permalink
Fix move nested if statement (#11688)
Browse files Browse the repository at this point in the history
  • Loading branch information
MrErlison authored and rikatz committed Oct 3, 2024
1 parent ea5e2cd commit c21b32b
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions internal/ingress/controller/template/crossplane/http.go
Original file line number Diff line number Diff line change
Expand Up @@ -107,9 +107,10 @@ func (c *Template) buildHTTP() {
if cfg.HTTP2MaxHeaderSize != "" && cfg.HTTP2MaxFieldSize != "" {
httpBlock = append(httpBlock, buildDirective("http2_max_field_size", cfg.HTTP2MaxFieldSize))
httpBlock = append(httpBlock, buildDirective("http2_max_header_size", cfg.HTTP2MaxHeaderSize))
if cfg.HTTP2MaxRequests > 0 {
httpBlock = append(httpBlock, buildDirective("http2_max_requests", cfg.HTTP2MaxRequests))
}
}

if cfg.HTTP2MaxRequests > 0 {
httpBlock = append(httpBlock, buildDirective("http2_max_requests", cfg.HTTP2MaxRequests))
}

if cfg.UseGzip {
Expand Down

0 comments on commit c21b32b

Please sign in to comment.