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

Commit

Permalink
Merge pull request #5 from arv/create-object-url-etc
Browse files Browse the repository at this point in the history
Copy over static methods
  • Loading branch information
dfreedm committed Jul 31, 2014
2 parents 8fa5af1 + a933e52 commit 35e0e6a
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;

})(this);

0 comments on commit 35e0e6a

Please sign in to comment.