tolerate lack of addCheck which means is not running in dashboard mode

This commit is contained in:
Iuri Matias 2018-03-30 10:59:31 -04:00
parent 8907753dec
commit fffde9d4b6
1 changed files with 5 additions and 1 deletions

View File

@ -50,7 +50,11 @@ class IPFS {
self.logger.info('IPFS node is offline..');
});
this.addCheck('IPFS', function (cb) {
if (!self.addCheck) {
return;
}
self.addCheck('IPFS', function (cb) {
self.logger.trace("Checking IPFS version...");
utils.httpGetJson('http://' + self.host + ':' + self.port + '/api/v0/version', function (err, body) {
if (err) {