mirror of
https://github.com/minio/minio.git
synced 2024-12-24 22:25:54 -05:00
Fix retention enforcement check for deleted object versions (#13240)
if an object is pending version purge, it should be treated as ErrNone in retention enforcement check
This commit is contained in:
parent
6d42569ade
commit
18f008f7c7
@ -93,7 +93,7 @@ func enforceRetentionBypassForDelete(ctx context.Context, r *http.Request, bucke
|
|||||||
if gerr != nil { // error from GetObjectInfo
|
if gerr != nil { // error from GetObjectInfo
|
||||||
switch gerr.(type) {
|
switch gerr.(type) {
|
||||||
case MethodNotAllowed: // This happens usually for a delete marker
|
case MethodNotAllowed: // This happens usually for a delete marker
|
||||||
if oi.DeleteMarker {
|
if oi.DeleteMarker || !oi.VersionPurgeStatus.Empty() {
|
||||||
// Delete marker should be present and valid.
|
// Delete marker should be present and valid.
|
||||||
return ErrNone
|
return ErrNone
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user