From bec89fffb7fbb711bea579042f120a36b92798d6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rafa=C5=82=20Foks?= Date: Fri, 13 Oct 2023 17:39:39 +0200 Subject: [PATCH] Fix linter --- controllers/compassmanager_controller.go | 1 - controllers/registrator.go | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/controllers/compassmanager_controller.go b/controllers/compassmanager_controller.go index f936719..a5877db 100644 --- a/controllers/compassmanager_controller.go +++ b/controllers/compassmanager_controller.go @@ -115,7 +115,6 @@ func (cm *CompassManagerReconciler) Reconcile(ctx context.Context, req ctrl.Requ return ctrl.Result{}, errors.Wrapf(err, "failed to perform unregistration stage for Kyma %s", req.Name) } return ctrl.Result{}, nil - } else if err != nil { return ctrl.Result{}, errors.Wrapf(err, "failed to obtain labels from Kyma resource %s", req.Name) } diff --git a/controllers/registrator.go b/controllers/registrator.go index 75f5fcf..6dbadde 100644 --- a/controllers/registrator.go +++ b/controllers/registrator.go @@ -51,7 +51,7 @@ func (r *CompassRegistrator) RegisterInCompass(compassRuntimeLabels map[string]i } func (r *CompassRegistrator) DeregisterFromCompass(compassID, globalAccount string) error { - err := util.RetryOnError(extendedRetryTime*time.Second, 3, "Error while unregistering runtime in Director: %s", func() (err apperrors.AppError) { + err := util.RetryOnError(extendedRetryTime*time.Second, attempts, "Error while unregistering runtime in Director: %s", func() (err apperrors.AppError) { err = r.Client.DeleteRuntime(compassID, globalAccount) return })