Skip to content

Commit

Permalink
companion: rename S3 upload functions to clarify which type of upload…
Browse files Browse the repository at this point in the history
… they do

cc @ifedapoolarewaju
  • Loading branch information
goto-bus-stop committed Jan 13, 2020
1 parent 1463ee7 commit fec7d7d
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions packages/@uppy/companion/src/server/Uploader.js
Original file line number Diff line number Diff line change
Expand Up @@ -236,7 +236,7 @@ class Uploader {
}

if (protocol === PROTOCOLS.s3Multipart && !this.s3Upload) {
return this.uploadS3()
return this.uploadS3Multipart()
}
// @TODO disabling parallel uploads and downloads for now
// if (!this.options.endpoint) return
Expand Down Expand Up @@ -492,7 +492,7 @@ class Uploader {
/**
* Upload the file to S3 while it is still being downloaded.
*/
uploadS3 () {
uploadS3Multipart () {
const file = createTailReadStream(this.path, {
tail: true
})
Expand All @@ -501,13 +501,13 @@ class Uploader {
file.close()
})

return this._uploadS3(file)
return this._uploadS3MultipartStream(file)
}

/**
* Upload a stream to S3.
*/
_uploadS3 (stream) {
_uploadS3MultipartStream (stream) {
if (!this.options.s3) {
this.emitError(new Error('The S3 client is not configured on this companion instance.'))
return
Expand Down

0 comments on commit fec7d7d

Please sign in to comment.