stable name label value

This commit is contained in:
aexel90 2020-12-28 10:05:54 +01:00
parent 95d43ee327
commit a0e0927d04

View file

@ -182,7 +182,9 @@ func getLabelValues(labelNames []string, result map[string]interface{}) ([]strin
labelValues := []string{} labelValues := []string{}
for _, labelname := range labelNames { for _, labelname := range labelNames {
labelValue := fmt.Sprintf("%v", result[labelname]) labelValue := fmt.Sprintf("%v", result[labelname])
if labelname != "Name" {
labelValue = strings.ToLower(labelValue) labelValue = strings.ToLower(labelValue)
}
labelValues = append(labelValues, labelValue) labelValues = append(labelValues, labelValue)
} }
return labelValues, nil return labelValues, nil