4d653fca by Adam Heath

Remove Function.prototype.bind monkey patch; this was due to an older

version of phantomjs that didn't have that method.
1 parent 2003e213
...@@ -453,28 +453,6 @@ module.exports = function (grunt) { ...@@ -453,28 +453,6 @@ module.exports = function (grunt) {
453 }); 453 });
454 var requireCallback = function requireCallback(mpConfigBase, withCoverage) { 454 var requireCallback = function requireCallback(mpConfigBase, withCoverage) {
455 /* global requirejs:false */ 455 /* global requirejs:false */
456 Function.prototype.bind = function bind() {
457 if (typeof this !== 'function') {
458 // closest thing possible to the ECMAScript 5
459 // internal IsCallable function
460 throw new TypeError('Function.prototype.bind - what is trying to be bound is not callable');
461 }
462
463 var aArgs = Array.prototype.slice.call(arguments, 1),
464 fToBind = this,
465 NOP = function() {},
466 fBound = function() {
467 return fToBind.apply(this, aArgs.concat(Array.prototype.slice.call(arguments)));
468 };
469
470 if (this.prototype) {
471 // Function.prototype doesn't have a prototype property
472 NOP.prototype = this.prototype;
473 }
474 fBound.prototype = new NOP();
475
476 return fBound;
477 };
478 requirejs.load = (function(oldLoad) { 456 requirejs.load = (function(oldLoad) {
479 return function (context, moduleName, url) { 457 return function (context, moduleName, url) {
480 //console.log('context=' + JSON.stringify(arguments), 'moduleName=' + moduleName, 'url=' + url); 458 //console.log('context=' + JSON.stringify(arguments), 'moduleName=' + moduleName, 'url=' + url);
......