Skip to content

Commit f20f114

Browse files
committed
Do not set the default value
1 parent 5c4a331 commit f20f114

1 file changed

Lines changed: 1 addition & 2 deletions

File tree

pkg/cvo/metrics.go

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -473,9 +473,8 @@ func (m *operatorMetrics) collectConditionalUpdateRisks(ch chan<- prometheus.Met
473473
g := m.clusterVersionRiskConditions.WithLabelValues(condition.Type, risk.Name)
474474
if condition.Status == metav1.ConditionTrue {
475475
g.Set(1)
476-
} else {
477-
g.Set(0)
478476
}
477+
// We do not need to do g.Set(0) as it is done when g is initialized
479478
ch <- g
480479
}
481480
}

0 commit comments

Comments
 (0)