readMetaData gets the metadata if it hasn't already been fetched it also sets the info
(ctx context.Context)
| 4014 | // |
| 4015 | // it also sets the info |
| 4016 | func (o *Object) readMetaData(ctx context.Context) (err error) { |
| 4017 | if o.meta != nil { |
| 4018 | return nil |
| 4019 | } |
| 4020 | resp, err := o.headObject(ctx) |
| 4021 | if err != nil { |
| 4022 | return err |
| 4023 | } |
| 4024 | o.setMetaData(resp) |
| 4025 | // resp.ETag, resp.ContentLength, resp.LastModified, resp.Metadata, resp.ContentType, resp.StorageClass) |
| 4026 | return nil |
| 4027 | } |
| 4028 | |
| 4029 | // Convert S3 metadata into a map[string]string while lowercasing the |
| 4030 | // keys |
no test coverage detected