From 0b08ca9ae0a8c2cba91ec627eeb15c237f180fe9 Mon Sep 17 00:00:00 2001 From: Holger Obermaier <40787752+ho-ob@users.noreply.github.com> Date: Fri, 11 Mar 2022 14:09:22 +0100 Subject: [PATCH] Simplified iota usage --- collectors/netstatMetric.go | 34 +++++++++++++++++----------------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/collectors/netstatMetric.go b/collectors/netstatMetric.go index 4bfc7ab..5e779e3 100644 --- a/collectors/netstatMetric.go +++ b/collectors/netstatMetric.go @@ -46,23 +46,23 @@ func (m *NetstatCollector) Init(config json.RawMessage) error { } const ( - fieldInterface = iota - fieldReceiveBytes = iota - fieldReceivePackets = iota - fieldReceiveErrs = iota - fieldReceiveDrop = iota - fieldReceiveFifo = iota - fieldReceiveFrame = iota - fieldReceiveCompressed = iota - fieldReceiveMulticast = iota - fieldTransmitBytes = iota - fieldTransmitPackets = iota - fieldTransmitErrs = iota - fieldTransmitDrop = iota - fieldTransmitFifo = iota - fieldTransmitColls = iota - fieldTransmitCarrier = iota - fieldTransmitCompressed = iota + fieldInterface = iota + fieldReceiveBytes + fieldReceivePackets + fieldReceiveErrs + fieldReceiveDrop + fieldReceiveFifo + fieldReceiveFrame + fieldReceiveCompressed + fieldReceiveMulticast + fieldTransmitBytes + fieldTransmitPackets + fieldTransmitErrs + fieldTransmitDrop + fieldTransmitFifo + fieldTransmitColls + fieldTransmitCarrier + fieldTransmitCompressed ) m.matches = make(map[string][]NetstatCollectorMetric)