Reputation: 7013
I am using fineuploader with the the jquery wrapper and would like to cancel/destroy an instance when a certain event happens. Basically the uploader exists in a boostrap modal and when the modal is closed I would like to stop any uploading because it seems to break the browser if I dont and then later try again.
I see the onCancel callback but I do not see a way to call a cancel event or basically destroy the fineuploader.
Upvotes: 2
Views: 1292
Reputation: 19890
Don't access "private" functions/properties. These may change or disappear at any time. I added a cancelAll
API function in 3.3. You can use that.
Upvotes: 3
Reputation: 7013
This seems to do the trick
$('selector').data('fineuploader').uploader._handler.cancelAll();
Upvotes: 0