From 8c73d0ce88c31c30ba5bb96039ddac809a4c64a2 Mon Sep 17 00:00:00 2001 From: TwinProduction Date: Fri, 23 Oct 2020 16:35:40 -0400 Subject: [PATCH] Minor improvement --- alerting/provider/custom/custom.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/alerting/provider/custom/custom.go b/alerting/provider/custom/custom.go index c1a72d75..e0b5cad9 100644 --- a/alerting/provider/custom/custom.go +++ b/alerting/provider/custom/custom.go @@ -81,9 +81,8 @@ func (provider *AlertProvider) Send(serviceName, alertDescription string, resolv body, err := ioutil.ReadAll(response.Body) if err != nil { return nil, fmt.Errorf("call to provider alert returned status code %d", response.StatusCode) - } else { - return nil, fmt.Errorf("call to provider alert returned status code %d: %s", response.StatusCode, string(body)) } + return nil, fmt.Errorf("call to provider alert returned status code %d: %s", response.StatusCode, string(body)) } return ioutil.ReadAll(response.Body) }