mirror of
https://github.com/moby/moby.git
synced 2026-01-11 18:51:37 +00:00
Remove redundant error message
Currently some commands including `kill`, `pause`, `restart`, `rm`, `rmi`, `stop`, `unpause`, `udpate`, `wait` will print a lot of error message on client side, with a lot of redundant messages, this commit is trying to remove the unuseful and redundant information for user. Signed-off-by: Zhang Wei <zhangwei555@huawei.com>
This commit is contained in:
@@ -20,7 +20,7 @@ func (daemon *Daemon) ContainerStop(name string, seconds int) error {
|
||||
return err
|
||||
}
|
||||
if !container.IsRunning() {
|
||||
return derr.ErrorCodeStopped
|
||||
return derr.ErrorCodeStopped.WithArgs(name)
|
||||
}
|
||||
if err := daemon.containerStop(container, seconds); err != nil {
|
||||
return derr.ErrorCodeCantStop.WithArgs(name, err)
|
||||
|
||||
Reference in New Issue
Block a user