Method receiver 'ti' is not referenced in method's body, consider removing it
2170 return false
2171}
2172
2173func (ti *trieIndex) metricDataLen(ps *points.Points) int64 {2174 dataLen := int64(len(ps.Data))
2175 if dataLen == 0 {
2176 // WHY: in theory, this should not happen. But in cases where
Description
Methods with unused receivers can be a symptom of unfinished refactoring or a bug. To keep the same method signature, omit the receiver name or '_' as it is unused.
Bad practice
func (f *Unix) Name() string {
return "unix"
}
func (_ *Unix) Name() string {
return "unix"
}
Recommended
func (*Unix) Name() string {
return "unix"
}