Skip to content

Commit d391b70

Browse files
committed
fix: correct metadata key for calculated digest in S3 sync
1 parent 9b8f351 commit d391b70

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

internal/sync/s3.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -209,7 +209,7 @@ func syncObject(ctx context.Context, s3Session *s3.S3, bucket *string, key strin
209209
}
210210
}
211211

212-
headMetadataDigest, digestPresent := head.Metadata["calculatedDigest"]
212+
headMetadataDigest, digestPresent := head.Metadata["X-Calculated-Digest"]
213213

214214
if head == nil ||
215215
head.ContentType == nil ||
@@ -229,7 +229,7 @@ func syncObject(ctx context.Context, s3Session *s3.S3, bucket *string, key strin
229229
ACL: acl,
230230
ContentType: contentType,
231231
Metadata: map[string]*string{
232-
"calculatedDigest": aws.String(calculatedDigest),
232+
"X-Calculated-Digest": aws.String(calculatedDigest),
233233
},
234234
}); err != nil {
235235
return err

0 commit comments

Comments
 (0)