Do not check and return strconv.Atoi error in api container restart, regression

Signed-off-by: Antonio Murdaca <me@runcom.ninja>
This commit is contained in:
Antonio Murdaca
2015-05-07 01:49:16 +02:00
parent 4b4adae41c
commit 74121a4211
2 changed files with 20 additions and 4 deletions
+1 -4
View File
@@ -917,10 +917,7 @@ func (s *Server) postContainersRestart(version version.Version, w http.ResponseW
return fmt.Errorf("Missing parameter")
}
timeout, err := strconv.Atoi(r.Form.Get("t"))
if err != nil {
return err
}
timeout, _ := strconv.Atoi(r.Form.Get("t"))
if err := s.daemon.ContainerRestart(vars["name"], timeout); err != nil {
return err