From 1e10fc2e306ae74c5a4894785e6e0afe57fe86e3 Mon Sep 17 00:00:00 2001 From: Regner Blok-Andersen Date: Tue, 14 Feb 2017 14:57:09 -0800 Subject: [PATCH] Simplifying else if statement to be cleaner --- provider/kubernetes.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/provider/kubernetes.go b/provider/kubernetes.go index b8e37fdb2..6fe6ca848 100644 --- a/provider/kubernetes.go +++ b/provider/kubernetes.go @@ -218,7 +218,9 @@ func (provider *Kubernetes) loadIngresses(k8sClient k8s.Client) (*types.Configur if err != nil { log.Errorf("Error while retrieving endpoints from k8s API %s/%s: %v", service.ObjectMeta.Namespace, service.ObjectMeta.Name, err) continue - } else if !exists { + } + + if !exists { log.Errorf("Service not found for %s/%s", service.ObjectMeta.Namespace, service.ObjectMeta.Name) continue }