Skip to content

Commit

Permalink
Merge pull request #706
Browse files Browse the repository at this point in the history
fix(config): reverse proxy ip ranges parse warning when unset
  • Loading branch information
muety authored Nov 11, 2024
2 parents f425367 + 3511090 commit 5bd1ffd
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions config/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -335,6 +335,11 @@ func (c *securityConfig) ParseTrustReverseProxyIPs() {
c.trustReverseProxyIpsParsed = make([]net.IPNet, 0)

for _, ip := range strings.Split(c.TrustReverseProxyIps, ",") {
// the config value is empty by default
if ip == "" {
continue
}

// try parse as address range
_, parsedIpNet, err := net.ParseCIDR(ip)
if err == nil {
Expand Down

0 comments on commit 5bd1ffd

Please sign in to comment.