Skip to content
This repository was archived by the owner on Aug 30, 2024. It is now read-only.

Commit 2b0bc77

Browse files
author
Faris Huskovic
committed
use clog.Fatal if more than one image is returned
1 parent 925cb18 commit 2b0bc77

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

internal/cmd/ceapi.go

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -102,12 +102,10 @@ func findImg(ctx context.Context, client *coder.Client, email, imgName string) (
102102
lines = append(lines, img.Repository)
103103
}
104104

105-
clog.LogInfo(
105+
clog.Fatal(
106106
fmt.Sprintf("Found %d possible matches for %q.", numImgs, imgName),
107107
clog.Tipf("Did you mean?\n\t%s", strings.Join(lines, "\n\t")),
108108
)
109-
110-
return nil, xerrors.New("please refine your search")
111109
}
112110
return &userImgs[0], nil
113111
}

0 commit comments

Comments
 (0)