mirror of
https://github.com/minio/minio.git
synced 2025-11-27 20:58:55 -05:00
committed by
Nitish Tiwari
parent
83d7ec09c1
commit
aebfceeafb
@@ -205,10 +205,6 @@ func healBucketMetadata(xl xlObjects, bucket string, dryRun bool) (
|
||||
reqInfo := &logger.ReqInfo{BucketName: bucket}
|
||||
ctx := logger.SetReqInfo(context.Background(), reqInfo)
|
||||
result, healErr := xl.HealObject(ctx, minioMetaBucket, metaPath, dryRun)
|
||||
// If object is not found, no result to add.
|
||||
if isErrObjectNotFound(healErr) {
|
||||
return nil
|
||||
}
|
||||
if healErr != nil {
|
||||
return healErr
|
||||
}
|
||||
@@ -608,6 +604,12 @@ func (xl xlObjects) healObjectDir(ctx context.Context, bucket, object string, dr
|
||||
// and later the disk comes back up again, heal on the object
|
||||
// should delete it.
|
||||
func (xl xlObjects) HealObject(ctx context.Context, bucket, object string, dryRun bool) (hr madmin.HealResultItem, err error) {
|
||||
defer func() {
|
||||
// If object is not found, ignore the error.
|
||||
if isErrObjectNotFound(err) {
|
||||
err = nil
|
||||
}
|
||||
}()
|
||||
|
||||
// Create context that also contains information about the object and bucket.
|
||||
// The top level handler might not have this information.
|
||||
|
||||
Reference in New Issue
Block a user