From da0e7c7bdccd7cce78343217e53cc4e3a961d3c1 Mon Sep 17 00:00:00 2001 From: lou-lan Date: Tue, 14 Jan 2020 15:11:22 +0800 Subject: [PATCH] Clean code (Condition is always 'false' because 'err' is always 'nil' ). --- pkg/util/image_util.go | 4 ---- 1 file changed, 4 deletions(-) diff --git a/pkg/util/image_util.go b/pkg/util/image_util.go index 4b74c7d38..a654e815c 100644 --- a/pkg/util/image_util.go +++ b/pkg/util/image_util.go @@ -123,10 +123,6 @@ func remoteImage(image string, opts *config.KanikoOptions) (v1.Image, error) { } rOpts := remoteOptions(registryName, opts) - if err != nil { - return nil, err - } - return remote.Image(ref, rOpts...) }