log/filtered/filtered.go
func (f *Filtered) WithFields(fields log.Fields) log.Interface {
	res := make(map[string]interface{}, len(fields))

	for k, v := range fields {
		val := v

		// apply the filters
		for _, filter := range f.filters {
			val = filter.Filter(k, val)
		}

		res[k] = val
	}

	return &Filtered{
		Interface: f.Interface.WithFields(res),
		filters:   f.filters,
	}
}
func (f *Filtered) WithFields(fields log.Fields) log.Interface {
	res := make(map[string]interface{}, len(fields))

	for k, v := range fields {
		val := v

		// apply the filters
		for _, filter := range f.filters {
			val = filter.Filter(k, val)
		}

		res[k] = val
	}

	return &Filtered{
		Interface: f.Interface.WithFields(res),
		filters:   f.filters,
	}
}
// WithFields filters the fields and passes them on to the wrapped loggers WithFields