mirror of
https://github.com/embarklabs/embark.git
synced 2025-01-28 22:45:48 +00:00
fix little oopsie in waterfall
This commit is contained in:
parent
b003675ee8
commit
8d9c192e91
@ -109,13 +109,14 @@ class Blockchain {
|
|||||||
|
|
||||||
registerServiceCheck() {
|
registerServiceCheck() {
|
||||||
const self = this;
|
const self = this;
|
||||||
|
const NO_NODE = 'noNode';
|
||||||
|
|
||||||
this.addCheck('Ethereum', function (cb) {
|
this.addCheck('Ethereum', function (cb) {
|
||||||
async.waterfall([
|
async.waterfall([
|
||||||
function checkNodeConnection(next) {
|
function checkNodeConnection(next) {
|
||||||
self.assertNodeConnection(true, (err) => {
|
self.assertNodeConnection(true, (err) => {
|
||||||
if (err) {
|
if (err) {
|
||||||
return next(null, {name: "No Blockchain node found", status: 'off'});
|
return next(NO_NODE, {name: "No Blockchain node found", status: 'off'});
|
||||||
}
|
}
|
||||||
next();
|
next();
|
||||||
});
|
});
|
||||||
@ -137,6 +138,9 @@ class Blockchain {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
], (err, statusObj) => {
|
], (err, statusObj) => {
|
||||||
|
if (err === NO_NODE) {
|
||||||
|
return cb(err);
|
||||||
|
}
|
||||||
if (err) {
|
if (err) {
|
||||||
self.logger.error(err);
|
self.logger.error(err);
|
||||||
return;
|
return;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user