Call shutdown() of msg network modules @ shutdown

This commit is contained in:
Bryan Ashby 2016-06-20 21:05:47 -06:00
parent b17bd15c46
commit 97c2e7adc0
2 changed files with 21 additions and 9 deletions

View file

@ -100,10 +100,15 @@ function shutdownSystem() {
},
function stopEventScheduler(callback) {
if(initServices.eventScheduler) {
return initServices.eventScheduler.shutdown(callback);
return initServices.eventScheduler.shutdown( () => {
callback(null); // ignore err
});
} else {
return callback(null);
}
},
function stopMsgNetwork(callback) {
require('./msg_network.js').shutdown(callback);
}
],
() => {