check for cmd not found in stderr

This commit is contained in:
Iuri Matias 2018-07-04 16:40:46 +03:00
parent ace329ec6e
commit 0f6ea45f33
1 changed files with 2 additions and 2 deletions

View File

@ -221,8 +221,8 @@ Blockchain.prototype.checkPathLength = function() {
Blockchain.prototype.isClientInstalled = function(callback) {
let versionCmd = this.client.determineVersionCommand();
this.runCommand(versionCmd, {}, (err, stdout, _stderr) => {
if (err || !stdout || stdout.indexOf("not found") >= 0) {
this.runCommand(versionCmd, {}, (err, stdout, stderr) => {
if (err || !stdout || stderr.indexOf("not found") >= 0 || stdout.indexOf("not found") >= 0) {
return callback('Geth not found');
}
callback();