make it more safer
This commit is contained in:
parent
6f666c7bd2
commit
15e70e5e63
|
@ -92,7 +92,7 @@ func NormalizeMetricFamilies(metricFamiliesByName map[string]*dto.MetricFamily)
|
|||
result = append(result, mf)
|
||||
}
|
||||
sort.Slice(result, func(i, j int) bool {
|
||||
return *result[i].Name < *result[j].Name
|
||||
return result[i].GetName() < result[j].GetName()
|
||||
})
|
||||
return result
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue