summaryrefslogtreecommitdiffstats
path: root/vendor/github.com/minio/minio-go/api-get-object.go
diff options
context:
space:
mode:
authorChristopher Speller <crspeller@gmail.com>2017-08-17 17:19:06 -0700
committerGitHub <noreply@github.com>2017-08-17 17:19:06 -0700
commit96eab1202717e073782ec399a4e0820cae15b1bb (patch)
tree011012982be971c7e9ef91466f026bc0956ac9a2 /vendor/github.com/minio/minio-go/api-get-object.go
parent2c895ee66eed626721135acfcc48254c6e3f3b29 (diff)
downloadchat-96eab1202717e073782ec399a4e0820cae15b1bb.tar.gz
chat-96eab1202717e073782ec399a4e0820cae15b1bb.tar.bz2
chat-96eab1202717e073782ec399a4e0820cae15b1bb.zip
Updating server dependancies. (#7246)
Diffstat (limited to 'vendor/github.com/minio/minio-go/api-get-object.go')
-rw-r--r--vendor/github.com/minio/minio-go/api-get-object.go18
1 files changed, 12 insertions, 6 deletions
diff --git a/vendor/github.com/minio/minio-go/api-get-object.go b/vendor/github.com/minio/minio-go/api-get-object.go
index 1078d2f98..9bd784ffa 100644
--- a/vendor/github.com/minio/minio-go/api-get-object.go
+++ b/vendor/github.com/minio/minio-go/api-get-object.go
@@ -679,12 +679,18 @@ func (c Client) getObject(bucketName, objectName string, reqHeaders RequestHeade
if contentType == "" {
contentType = "application/octet-stream"
}
- var objectStat ObjectInfo
- objectStat.ETag = md5sum
- objectStat.Key = objectName
- objectStat.Size = resp.ContentLength
- objectStat.LastModified = date
- objectStat.ContentType = contentType
+
+ objectStat := ObjectInfo{
+ ETag: md5sum,
+ Key: objectName,
+ Size: resp.ContentLength,
+ LastModified: date,
+ ContentType: contentType,
+ // Extract only the relevant header keys describing the object.
+ // following function filters out a list of standard set of keys
+ // which are not part of object metadata.
+ Metadata: extractObjMetadata(resp.Header),
+ }
// do not close body here, caller will close
return resp.Body, objectStat, nil