Skip to content

Commit 2bbed69

Browse files
committed
Workaround an exception in Gecko when using Blob.prototype.slice as widget property.
The exception thrown was "Illegal operation on WrappedNative prototype object" and occurs due to the proxying of the jQuery UI widget methods.
1 parent e51e39c commit 2bbed69

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

js/jquery.fileupload.js

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* jQuery File Upload Plugin 5.31.4
2+
* jQuery File Upload Plugin 5.31.5
33
* https://github.com/blueimp/jQuery-File-Upload
44
*
55
* Copyright 2010, Sebastian Tschan
@@ -233,8 +233,10 @@
233233
'forceIframeTransport'
234234
],
235235

236-
_blobSlice: window.Blob && (Blob.prototype.slice ||
237-
Blob.prototype.webkitSlice || Blob.prototype.mozSlice),
236+
_blobSlice: function () {
237+
var slice = this.slice || this.webkitSlice || this.mozSlice;
238+
return slice.apply(this, arguments);
239+
},
238240

239241
_BitrateTimer: function () {
240242
this.timestamp = ((Date.now) ? Date.now() : (new Date()).getTime());

0 commit comments

Comments
 (0)