remove aliases for containerd/errdefs, disallow docker/errdefs
We transitioned most functionality of docker/errdefs to containerd errdefs module, and the docker/errdefs package should no longer be used. Because of that, there will no longer be ambiguity, so we can remove the aliases for this package, and use it as "errdefs". Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
@ -5,7 +5,7 @@ import (
|
||||
"fmt"
|
||||
"strconv"
|
||||
|
||||
cerrdefs "github.com/containerd/errdefs"
|
||||
"github.com/containerd/errdefs"
|
||||
"github.com/docker/cli/cli"
|
||||
"github.com/docker/cli/cli/command"
|
||||
"github.com/docker/cli/cli/command/completion"
|
||||
@ -59,7 +59,7 @@ func runRemove(ctx context.Context, dockerCLI command.Cli, networks []string, op
|
||||
}
|
||||
}
|
||||
if err := apiClient.NetworkRemove(ctx, name); err != nil {
|
||||
if opts.force && cerrdefs.IsNotFound(err) {
|
||||
if opts.force && errdefs.IsNotFound(err) {
|
||||
continue
|
||||
}
|
||||
_, _ = fmt.Fprintln(dockerCLI.Err(), err)
|
||||
|
||||
Reference in New Issue
Block a user