Commit 812461f9 812461f95e1b40c3c2ccbddb95c53fd0cc44a544 by Laurent Jouanneau

Fix bootstrap: global should be this, not window

In a javascript context, all JS function are not all attached to the window object.
This is the case of 'native' functions. In SlimerJS, the 'require' function is
not attached to the window object. It is a standalone function.
1 parent b6edadf7
...@@ -309,4 +309,4 @@ CasperError.prototype = Object.getPrototypeOf(new Error()); ...@@ -309,4 +309,4 @@ CasperError.prototype = Object.getPrototypeOf(new Error());
309 if (phantom.casperScript && !phantom.injectJs(phantom.casperScript)) { 309 if (phantom.casperScript && !phantom.injectJs(phantom.casperScript)) {
310 return __die('Unable to load script ' + phantom.casperScript + '; check file syntax'); 310 return __die('Unable to load script ' + phantom.casperScript + '; check file syntax');
311 } 311 }
312 })(window, phantom); 312 })(this, phantom);
......