Browse code

fixed an issue with the help history command, printed twice

Ken Cochrane authored on 2013/03/26 10:33:56
Showing 1 changed files
... ...
@@ -297,7 +297,10 @@ func (srv *Server) CmdRmi(stdin io.ReadCloser, stdout io.Writer, args ...string)
297 297
 
298 298
 func (srv *Server) CmdHistory(stdin io.ReadCloser, stdout io.Writer, args ...string) error {
299 299
 	cmd := rcli.Subcmd(stdout, "history", "[OPTIONS] IMAGE", "Show the history of an image")
300
-	if cmd.Parse(args) != nil || cmd.NArg() != 1 {
300
+	if err := cmd.Parse(args); err != nil {
301
+		return nil
302
+	}
303
+	if cmd.NArg() != 1 {
301 304
 		cmd.Usage()
302 305
 		return nil
303 306
 	}