mirror of
https://github.com/moby/moby.git
synced 2026-01-11 18:51:37 +00:00
fix use-errors-new from revive
Signed-off-by: Matthieu MOREL <matthieu.morel35@gmail.com>
This commit is contained in:
@@ -2,7 +2,6 @@ package daemon
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
|
||||
cerrdefs "github.com/containerd/errdefs"
|
||||
"github.com/docker/docker/api/types/container"
|
||||
@@ -56,7 +55,7 @@ func (daemon *Daemon) update(name string, hostConfig *container.HostConfig) erro
|
||||
|
||||
if ctr.RemovalInProgress || ctr.Dead {
|
||||
ctr.Unlock()
|
||||
return errCannotUpdate(ctr.ID, fmt.Errorf(`container is marked for removal and cannot be "update"`))
|
||||
return errCannotUpdate(ctr.ID, errors.New(`container is marked for removal and cannot be "update"`))
|
||||
}
|
||||
|
||||
if err := ctr.UpdateContainer(hostConfig); err != nil {
|
||||
|
||||
Reference in New Issue
Block a user