diff --git a/web/api/v1/api.go b/web/api/v1/api.go index 09bcaa1aa91..a020c6e036f 100644 --- a/web/api/v1/api.go +++ b/web/api/v1/api.go @@ -1164,7 +1164,7 @@ func renderTargetData(targets map[string][]TargetServiceDiscovery) TargetDiscove res.DroppedTargets = append(res.DroppedTargets, &DroppedTarget{ DiscoveredLabels: target.discoveredLabels.Map(), }) - res.DroppedTargetCounts[job] = res.DroppedTargetCounts[job] + 1 + res.DroppedTargetCounts[job]++ } else { res.ActiveTargets = append(res.ActiveTargets, &Target{ DiscoveredLabels: target.discoveredLabels.Map(),