Browse Source

logging: Fix for IP filtering

master
Christoph Kluge 4 years ago
committed by GitHub
parent
commit
dd26875ffc
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      modules/logging/filters.go

2
modules/logging/filters.go

@ -141,7 +141,7 @@ func (m IPMaskFilter) Filter(in zapcore.Field) zapcore.Field {
return in
}
mask := m.v4Mask
if ipAddr.To16() != nil {
if ipAddr.To4() == nil {
mask = m.v6Mask
}
masked := ipAddr.Mask(mask)

Loading…
Cancel
Save