From 15cad1348a3997c0c74f6b87bceb85cd8316e62c Mon Sep 17 00:00:00 2001 From: christianulson Date: Thu, 21 Mar 2019 03:50:22 -0300 Subject: [PATCH] fix upload --- projects/ngx-uploader/src/lib/ngx-uploader.class.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/projects/ngx-uploader/src/lib/ngx-uploader.class.ts b/projects/ngx-uploader/src/lib/ngx-uploader.class.ts index ca5109a6..53d41ff5 100644 --- a/projects/ngx-uploader/src/lib/ngx-uploader.class.ts +++ b/projects/ngx-uploader/src/lib/ngx-uploader.class.ts @@ -194,7 +194,7 @@ export class NgUploaderService { }); xhr.onreadystatechange = () => { - if (xhr.readyState === XMLHttpRequest.DONE) { + if (xhr.readyState === xhr.DONE) { const speedAverage = Math.round(file.size / (new Date().getTime() - progressStartTime) * 1000); file.progress = { status: UploadStatus.Done,