mirror of
https://github.com/minio/minio.git
synced 2026-11-13 14:44:19 +00:00
fix: case-insensitive lookups for metadata (#11489)
continuation of #11487, with more changes
This commit is contained in:
1 parent
f9c5636c2d
commit
68d299e719
6 files changed
+69
-41
No files matched your search
@@ -179,7 +179,7 @@ func (er erasureObjects) GetObjectNInfo(ctx context.Context, bucket, object stri
|
||||
}
|
||||
if objInfo.TransitionStatus == lifecycle.TransitionComplete {
|
||||
// If transitioned, stream from transition tier unless object is restored locally or restore date is past.
|
||||
restoreHdr, ok := getMapValue(objInfo.UserDefined, xhttp.AmzRestore)
|
||||
restoreHdr, ok := caseInsensitiveMap(objInfo.UserDefined).Lookup(xhttp.AmzRestore)
|
||||
if !ok || !strings.HasPrefix(restoreHdr, "ongoing-request=false") || (!objInfo.RestoreExpires.IsZero() && time.Now().After(objInfo.RestoreExpires)) {
|
||||
return getTransitionedObjectReader(ctx, bucket, object, rs, h, objInfo, opts)
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user