Skip to content

Commit

Permalink
chore(lib-storage): add required checksum values to CompletedPart array
Browse files Browse the repository at this point in the history
  • Loading branch information
trivikr committed Feb 24, 2022
1 parent ec3cc1e commit 9c2d945
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions lib/lib-storage/src/Upload.ts
Expand Up @@ -159,6 +159,10 @@ export class Upload extends EventEmitter {
this.uploadedParts.push({
PartNumber: dataPart.partNumber,
ETag: partResult.ETag,
...(partResult.ChecksumCRC32 && { ChecksumCRC32: partResult.ChecksumCRC32 }),
...(partResult.ChecksumCRC32C && { ChecksumCRC32C: partResult.ChecksumCRC32C }),
...(partResult.ChecksumSHA1 && { ChecksumSHA1: partResult.ChecksumSHA1 }),
...(partResult.ChecksumSHA256 && { ChecksumSHA256: partResult.ChecksumSHA256 }),
});

this.bytesUploadedSoFar += byteLength(dataPart.data);
Expand Down

0 comments on commit 9c2d945

Please sign in to comment.