mirror of
https://github.com/moby/moby.git
synced 2022-11-09 12:21:53 -05:00
fixed issue with rmi help showing help twice
This commit is contained in:
parent
a9a439183d
commit
c9d93cd333
1 changed files with 4 additions and 1 deletions
|
@ -283,7 +283,10 @@ func (srv *Server) CmdPort(stdin io.ReadCloser, stdout io.Writer, args ...string
|
||||||
// 'docker rmi NAME' removes all images with the name NAME
|
// 'docker rmi NAME' removes all images with the name NAME
|
||||||
func (srv *Server) CmdRmi(stdin io.ReadCloser, stdout io.Writer, args ...string) (err error) {
|
func (srv *Server) CmdRmi(stdin io.ReadCloser, stdout io.Writer, args ...string) (err error) {
|
||||||
cmd := rcli.Subcmd(stdout, "rmimage", "[OPTIONS] IMAGE", "Remove an image")
|
cmd := rcli.Subcmd(stdout, "rmimage", "[OPTIONS] IMAGE", "Remove an image")
|
||||||
if cmd.Parse(args) != nil || cmd.NArg() < 1 {
|
if err := cmd.Parse(args); err != nil {
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
if cmd.NArg() < 1 {
|
||||||
cmd.Usage()
|
cmd.Usage()
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue