Skip to content

Commit

Permalink
use ParseRepositoryTag instead on split on : in imagedelete
Browse files Browse the repository at this point in the history
  • Loading branch information
vieux committed Jul 29, 2013
1 parent 97a2dc9 commit 63876e7
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions server.go
Original file line number Diff line number Diff line change
Expand Up @@ -1037,13 +1037,7 @@ func (srv *Server) ImageDelete(name string, autoPrune bool) ([]APIRmi, error) {
return nil, nil
}

var tag string
if strings.Contains(name, ":") {
nameParts := strings.Split(name, ":")
name = nameParts[0]
tag = nameParts[1]
}

name, tag := utils.ParseRepositoryTag(name)
return srv.deleteImage(img, name, tag)
}

Expand Down

0 comments on commit 63876e7

Please sign in to comment.