Skip to content

Commit dd26fba

Browse files
authored
Merge pull request cli#11451 from cli/eugene/fetch-ref-handle-ReleaseNotFound
fix error for ErrReleaseNotFound when fetching ref
2 parents 588120b + 82eb05b commit dd26fba

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

pkg/cmd/release/shared/fetch.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -164,7 +164,8 @@ func FetchRefSHA(ctx context.Context, httpClient *http.Client, repo ghrepo.Inter
164164
} `json:"object"`
165165
}
166166
if err := json.NewDecoder(resp.Body).Decode(&ref); err != nil {
167-
return "", err
167+
// release not found
168+
return "", ErrReleaseNotFound
168169
}
169170

170171
return ref.Object.SHA, nil

0 commit comments

Comments
 (0)