chore(deps): update dependency golangci/golangci-lint to v2.13.1 (master) (#2477)

Co-authored-by: Jan-Otto Kröpke <mail@jkroepke.de>
Signed-off-by: Jan-Otto Kröpke <mail@jkroepke.de>
This commit is contained in:
renovate[bot]
2026-08-22 20:28:09 +02:00
committed by GitHub
co-authored by Jan-Otto Kröpke
parent 2743d4e3f7
commit 75b0c11bb4
11 changed files with 13 additions and 14 deletions
+1 -1
View File
@@ -304,7 +304,7 @@ func deduplicateIISNames[T collectorName](counterValues []T) {
// Use map to deduplicate IIS entries
for index, counterValue := range counterValues {
name := strings.Split(counterValue.GetName(), "#")[0]
name, _, _ := strings.Cut(counterValue.GetName(), "#")
if name == counterValue.GetName() {
continue
}
@@ -328,7 +328,7 @@ func (c *Collector) collectObject(ch chan<- prometheus.Metric, perfDataObject Ob
continue
}
metricType, _ := field.Interface().(prometheus.ValueType)
metricType, _ := reflect.TypeAssert[prometheus.ValueType](field)
labels := make(prometheus.Labels, len(counter.Labels)+1)
+1 -1
View File
@@ -265,7 +265,7 @@ func (c *Collector) groupPrintJobs(printJobs []wmiPrintJob) map[PrintJobStatusGr
groupedPrintJobs := make(map[PrintJobStatusGroup]int)
for _, printJob := range printJobs {
printerName := strings.Split(printJob.Name, ",")[0]
printerName, _, _ := strings.Cut(printJob.Name, ",")
if c.config.PrinterExclude.MatchString(printerName) ||
!c.config.PrinterInclude.MatchString(printerName) {