Skip to content

Commit

Permalink
Await S3 image upload to not push too many of them to the background
Browse files Browse the repository at this point in the history
  • Loading branch information
benoit74 committed Dec 26, 2024
1 parent 2f5d5ed commit ea3db9b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Downloader.ts
Original file line number Diff line number Diff line change
Expand Up @@ -588,7 +588,7 @@ class Downloader {
// Check for the ETag and upload to cache
const etag = this.removeEtagWeakPrefix(mwResp.headers.etag)
if (etag) {
this.s3.uploadBlob(stripHttpFromUrl(url), mwResp.data, etag, mwResp.headers['content-type'], this.webp ? 'webp' : '1')
await this.s3.uploadBlob(stripHttpFromUrl(url), mwResp.data, etag, mwResp.headers['content-type'], this.webp ? 'webp' : '1')
}

// Proceed with image
Expand Down

0 comments on commit ea3db9b

Please sign in to comment.