Skip to content

Commit

Permalink
change apply to call
Browse files Browse the repository at this point in the history
  • Loading branch information
vczero committed Sep 28, 2014
1 parent b85c45f commit ec9a7d2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/OpenLayers/BaseTypes.js
Original file line number Diff line number Diff line change
Expand Up @@ -337,12 +337,12 @@ OpenLayers.Function = {
*/
bind: function(func, object) {
// create a reference to all arguments past the second one
var args = Array.prototype.slice.apply(arguments, [2]);
var args = Array.prototype.slice.call(arguments, 2);
return function() {
// Push on any additional arguments from the actual function call.
// These will come after those sent to the bind call.
var newArgs = args.concat(
Array.prototype.slice.apply(arguments, [0])
Array.prototype.slice.call(arguments, 0)
);
return func.apply(object, newArgs);
};
Expand Down

0 comments on commit ec9a7d2

Please sign in to comment.