Skip to content
This repository has been archived by the owner on Jun 6, 2019. It is now read-only.

Commit

Permalink
Copy over static methods
Browse files Browse the repository at this point in the history
Fixes #4
  • Loading branch information
arv committed Jul 28, 2014
1 parent bd26fad commit a933e52
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions url.js
Original file line number Diff line number Diff line change
Expand Up @@ -560,6 +560,19 @@
}
};

// Copy over the static methods
var OriginalURL = scope.URL;
if (OriginalURL) {
jURL.createObjectURL = function(blob) {
// IE extension allows a second optional options argument.
// http://msdn.microsoft.com/en-us/library/ie/hh772302(v=vs.85).aspx
return OriginalURL.createObjectURL.apply(OriginalURL, arguments);
};
jURL.revokeObjectURL = function(url) {
OriginalURL.revokeObjectURL(url);
};
}

scope.URL = jURL;

})(window);

0 comments on commit a933e52

Please sign in to comment.