From bb5976d72793b6fb19c45f2c84a438c94f0c7de9 Mon Sep 17 00:00:00 2001 From: Klaus Post Date: Mon, 17 Aug 2020 08:25:44 -0700 Subject: [PATCH] healbucket: Send object version ID (#10263) Based on our previous conversations I assume we should send the version id when healing an object. Maybe we should even list object versions and heal all? --- cmd/admin-heal-ops.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cmd/admin-heal-ops.go b/cmd/admin-heal-ops.go index f4caf08e2..ad9fc989f 100644 --- a/cmd/admin-heal-ops.go +++ b/cmd/admin-heal-ops.go @@ -876,9 +876,9 @@ func (h *healSequence) healBucket(bucket string, bucketsOnly bool) error { if h.object != "" { // Check if an object named as the objPrefix exists, // and if so heal it. - _, err := objectAPI.GetObjectInfo(h.ctx, bucket, h.object, ObjectOptions{}) + oi, err := objectAPI.GetObjectInfo(h.ctx, bucket, h.object, ObjectOptions{}) if err == nil { - if err = h.healObject(bucket, h.object, ""); err != nil { + if err = h.healObject(bucket, h.object, oi.VersionID); err != nil { return err } }