From 69384a9a0f72cb0c5065c0aea1fd15b38b4dbd1e Mon Sep 17 00:00:00 2001 From: Mayank Kapur Date: Wed, 24 Jul 2024 00:50:04 +0530 Subject: [PATCH] Removes redundant condition from toAPIBuildOptions in build.go Signed-off-by: Mayank Kapur --- cmd/compose/build.go | 4 ---- 1 file changed, 4 deletions(-) diff --git a/cmd/compose/build.go b/cmd/compose/build.go index 1c914134e18..ca9e0f25932 100644 --- a/cmd/compose/build.go +++ b/cmd/compose/build.go @@ -48,7 +48,6 @@ type buildOptions struct { func (opts buildOptions) toAPIBuildOptions(services []string) (api.BuildOptions, error) { var SSHKeys []types.SSHKey - var err error if opts.ssh != "" { id, path, found := strings.Cut(opts.ssh, "=") if !found && id != "default" { @@ -58,9 +57,6 @@ func (opts buildOptions) toAPIBuildOptions(services []string) (api.BuildOptions, ID: id, Path: path, }) - if err != nil { - return api.BuildOptions{}, err - } } builderName := opts.builder if builderName == "" {