* Replace fmt.Sprintf("%d", i)) by strconv.Itoa(i)

* Correct misspelled words
* Remove unused code
* Break up very long lines into multiple lines
* lp.NewMessage -> lp.NewMetric
This commit is contained in:
Holger Obermaier
2026-02-12 14:31:01 +01:00
parent 309bc32a24
commit 555ba9504a
19 changed files with 213 additions and 260 deletions

View File

@@ -12,6 +12,7 @@ import (
"fmt"
"regexp"
"slices"
"strconv"
"strings"
topo "github.com/ClusterCockpit/cc-metric-collector/pkg/ccTopology"
@@ -208,7 +209,7 @@ func infunc(a any, b any) (any, error) {
case []int:
return slices.Contains(total, match), nil
case string:
smatch := fmt.Sprintf("%d", match)
smatch := strconv.Itoa(match)
return strings.Contains(total, smatch), nil
}