Browse Source

constant

pull/7481/head
chrislu 3 weeks ago
parent
commit
32450f8b90
  1. 2
      weed/s3api/s3api_object_handlers_put.go

2
weed/s3api/s3api_object_handlers_put.go

@ -453,7 +453,7 @@ func (s3a *S3ApiServer) putToFiler(r *http.Request, uploadUrl string, dataReader
// - Even if a part has multiple chunks internally, its ETag is MD5 of entire part // - Even if a part has multiple chunks internally, its ETag is MD5 of entire part
// 2. For regular object uploads: only set Md5 for single-chunk uploads // 2. For regular object uploads: only set Md5 for single-chunk uploads
// - Multi-chunk regular objects use composite "md5-count" format // - Multi-chunk regular objects use composite "md5-count" format
isMultipartPart := strings.Contains(uploadUrl, "/.uploads/")
isMultipartPart := strings.Contains(filePath, "/"+s3_constants.MultipartUploadsFolder+"/")
if isMultipartPart || len(chunkResult.FileChunks) == 1 { if isMultipartPart || len(chunkResult.FileChunks) == 1 {
entry.Attributes.Md5 = md5Sum entry.Attributes.Md5 = md5Sum
} }

Loading…
Cancel
Save