Skip to content
This repository has been archived by the owner on Nov 20, 2018. It is now read-only.

Added removeFileRef method

Pre-release
Pre-release
Compare
Choose a tag to compare
@rnicholus rnicholus released this 30 Jan 05:35

Documented at http://docs.fineuploader.com/branch/develop/api/methods.html#removeFileRef.

This allows you to free any memory associated with a client-side generated Blob. This is something you might want to do after the file has been successfully uploaded. For example:

var uploader = new qq.FineUploaderBasic({
    request: {
        endpoint: '/my/upload/endpoint'
    },
    callbacks: {
        onComplete: function(id, name, response) {
           if (response.success && this.getFile(id).inMemoryBlob) {
              this.removeFileRef(id)
           }
        }
    }
})

// elsewhere
var someBlobCreatedClientSide = createBlob(...)
someBlobCreatedClientSide.inMemoryBlob = true

uploader.addFiles(someBlobCreatedClientSide)

re: #1711