From 91b7bc08a1ef802849222a6dcacc40d3d978d876 Mon Sep 17 00:00:00 2001 From: Uday Ruddarraju Date: Thu, 7 Mar 2019 15:16:27 -0800 Subject: [PATCH] Fixing minor error handling bug in static autoscaler --- cluster-autoscaler/core/static_autoscaler.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cluster-autoscaler/core/static_autoscaler.go b/cluster-autoscaler/core/static_autoscaler.go index c657a069518..ecd2fbc40d8 100644 --- a/cluster-autoscaler/core/static_autoscaler.go +++ b/cluster-autoscaler/core/static_autoscaler.go @@ -154,7 +154,7 @@ func (a *StaticAutoscaler) RunOnce(currentTime time.Time) errors.AutoscalerError nodeInfosForGroups, autoscalerError := getNodeInfosForGroups( readyNodes, a.nodeInfoCache, autoscalingContext.CloudProvider, autoscalingContext.ListerRegistry, daemonsets, autoscalingContext.PredicateChecker) - if err != nil { + if autoscalerError != nil { return autoscalerError.AddPrefix("failed to build node infos for node groups: ") }