From bbb0365d8db6cda62f5dfb6eaae22bca19fcf9d7 Mon Sep 17 00:00:00 2001 From: bonowang Date: Fri, 7 Jul 2017 17:59:44 +0800 Subject: [PATCH] remove useless code --- pkg/controller/podautoscaler/replica_calculator.go | 3 --- 1 file changed, 3 deletions(-) diff --git a/pkg/controller/podautoscaler/replica_calculator.go b/pkg/controller/podautoscaler/replica_calculator.go index b96cd59fcbc..361008583a5 100644 --- a/pkg/controller/podautoscaler/replica_calculator.go +++ b/pkg/controller/podautoscaler/replica_calculator.go @@ -250,9 +250,6 @@ func (c *ReplicaCalculator) calcPlainMetricReplicas(metrics metricsclient.PodMet // re-run the utilization calculation with our new numbers newUsageRatio, _ := metricsclient.GetMetricUtilizationRatio(metrics, targetUtilization) - if err != nil { - return 0, utilization, err - } if math.Abs(1.0-newUsageRatio) <= tolerance || (usageRatio < 1.0 && newUsageRatio > 1.0) || (usageRatio > 1.0 && newUsageRatio < 1.0) { // return the current replicas if the change would be too small,