Commit 1c3b0b8d 1c3b0b8de49e344b9f4ae4b1d4fb43b0b4c464e4 by Nicolas Perriault

fixed phantom.casperPath was always redefined by cli argument value

1 parent 35a1cff6
...@@ -56,8 +56,9 @@ ...@@ -56,8 +56,9 @@
56 }; 56 };
57 57
58 phantom.casperArgs = phantom.extractCasperArgs(phantom.args); 58 phantom.casperArgs = phantom.extractCasperArgs(phantom.args);
59 phantom.casperPath = phantom.casperArgs.options['casper-path']; 59 if (!phantom.casperPath) {
60 //console.log(JSON.stringify(phantom.casperArgs, null, 4)) 60 phantom.casperPath = phantom.casperArgs.options['casper-path'];
61 }
61 62
62 if (!phantom.casperPath) { 63 if (!phantom.casperPath) {
63 console.log('Cannot find CasperJS home path. Did you set phantom.casperPath or pass the --casper-path option?'); 64 console.log('Cannot find CasperJS home path. Did you set phantom.casperPath or pass the --casper-path option?');
......