From ee07d645b4918aa3d6401ca27480c2c0cbf40352 Mon Sep 17 00:00:00 2001 From: Paul Bellamy Date: Tue, 19 May 2015 10:46:04 +0100 Subject: [PATCH] golint cleanup of else block --- proxy/start_container_interceptor.go | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/proxy/start_container_interceptor.go b/proxy/start_container_interceptor.go index 88c391b3..f2e361e4 100644 --- a/proxy/start_container_interceptor.go +++ b/proxy/start_container_interceptor.go @@ -21,13 +21,11 @@ func (i *startContainerInterceptor) InterceptRequest(r *http.Request) error { } func (i *startContainerInterceptor) InterceptResponse(r *http.Response) error { - containerID := "" if subs := containerIDRegexp.FindStringSubmatch(r.Request.URL.Path); subs == nil { Warning.Printf("No container id found in request with path %s", r.Request.URL.Path) return nil - } else { - containerID = subs[1] } + containerID := subs[1] container, err := i.client.InspectContainer(containerID) if err != nil {