mirror of
https://github.com/transloadit/uppy.git
synced 2026-01-23 02:25:07 +00:00
companion: overwrite bytestotal for only tus uploads
This commit is contained in:
parent
1d4c9a5720
commit
d9ec8d28f4
1 changed files with 1 additions and 1 deletions
|
|
@ -225,7 +225,7 @@ class Uploader {
|
|||
*/
|
||||
emitProgress (bytesUploaded, bytesTotal) {
|
||||
bytesTotal = bytesTotal || this.options.size
|
||||
if (this.tus.options.uploadLengthDeferred && this.streamsEnded) {
|
||||
if (this.tus && this.tus.options.uploadLengthDeferred && this.streamsEnded) {
|
||||
bytesTotal = this.bytesWritten
|
||||
}
|
||||
const percentage = (bytesUploaded / bytesTotal * 100)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue