extract node name and version (so it displays just like in 2.6.0)

This commit is contained in:
Iuri Matias 2018-04-10 15:14:00 -04:00
parent 044759ef52
commit 9d261472f9
1 changed files with 5 additions and 1 deletions

View File

@ -216,7 +216,11 @@ class Engine {
if (err) {
return cb({name: "Ethereum node (version unknown)", status: 'on'});
}
return cb({name: version, status: 'on'});
let nodeName = version.split("/")[0];
let versionNumber = version.split("/")[1].split("-")[0];
let name = nodeName + " " + versionNumber + " (Ethereum)";
return cb({name: name, status: 'on'});
});
});
});