heal: Don't print info if heal obj returns an err (#1988)

When heal object returns an error, just print an error and continue with the
next objects.
This commit is contained in:
Anis Elleuch
2017-01-25 13:50:45 -08:00
committed by Harshavardhana
parent 9d7529118e
commit 3fefebd05d
+4 -1
View File
@@ -160,7 +160,10 @@ func mainAdminHeal(ctx *cli.Context) error {
case madmin.CanHeal:
// Heal Object
e = client.HealObject(bucket, obj.Key, isFake)
errorIf(probe.NewError(e), "Cannot repair object: `"+obj.Key+"`")
if e != nil {
errorIf(probe.NewError(e), "Cannot repair object: `"+obj.Key+"`")
continue
}
// Print successful message
printMsg(healObjectMessage{Bucket: bucket, Object: obj})