// setup for processing the progress of the upload uploadTask.on(firebase.storage.TaskEvent.STATE_CHANGED, (snapshot) => {
debugger let percent:number = Math.floor(snapshot.bytesTransferred / snapshot.totalBytes * 100);
//get all the files that are being uploaded for this file item let uploadingFiles:IUploading[] = this.filesUploading[snapshot.metadata.customMetadata.fileItemId];
// find the file that we gor the progress for uploadingFiles.forEach((v:IUploading) => { if(v.meta.customMetadata.uploadRef == snapshot.metadata.customMetadata.uploadRef) { v.uploadProgress = percent; v.bytesTransferred = snapshot.bytesTransferred; v.totalBytes = snapshot.totalBytes; } });
});--
You received this message because you are subscribed to the Google Groups "Firebase Google Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to firebase-tal...@googlegroups.com.
To post to this group, send email to fireba...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/firebase-talk/6bdeecd0-83d5-41c3-8e65-eb269be2cea9%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
| Alex Memering | | Software Engineer | | meme...@google.com |
To view this discussion on the web visit https://groups.google.com/d/msgid/firebase-talk/e9ba56a4-ee63-4d0f-a163-c38f956533c1%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.