From 0ac39a7ab5db077fcf0df827e32bf6e625e980da Mon Sep 17 00:00:00 2001 From: Michael Muré Date: Sat, 19 Nov 2022 11:33:12 +0100 Subject: WIP --- commands/bug/select/select.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'commands') diff --git a/commands/bug/select/select.go b/commands/bug/select/select.go index 908ad58c..42d65bc2 100644 --- a/commands/bug/select/select.go +++ b/commands/bug/select/select.go @@ -18,7 +18,7 @@ const selectFile = "select" var ErrNoValidId = errors.New("you must provide a bug id or use the \"select\" command first") // ResolveBug first try to resolve a bug using the first argument of the command -// line. If it fails, it fallback to the select mechanism. +// line. If it fails, it falls back to the select mechanism. // // Returns: // - the bug if any @@ -34,7 +34,7 @@ func ResolveBug(repo *cache.RepoCache, args []string) (*cache.BugCache, []string return b, args[1:], nil } - if err != bug.ErrBugNotExist { + if !entity.IsErrNotFound(err) { return nil, nil, err } } @@ -44,7 +44,7 @@ func ResolveBug(repo *cache.RepoCache, args []string) (*cache.BugCache, []string b, err := selected(repo) // selected bug is invalid - if err == bug.ErrBugNotExist { + if entity.IsErrNotFound(err) { // we clear the selected bug err = Clear(repo) if err != nil { -- cgit