From c2ee05bd5198c7ed8e12fd1f702b70e3971dce29 Mon Sep 17 00:00:00 2001 From: Bryan Ashby Date: Tue, 28 Jun 2016 23:06:35 -0600 Subject: [PATCH] Add callback to beforeArt --- core/menu_module.js | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/core/menu_module.js b/core/menu_module.js index e454ff58..03f7e2d6 100644 --- a/core/menu_module.js +++ b/core/menu_module.js @@ -46,8 +46,7 @@ function MenuModule(options) { async.series( [ function beforeDisplayArt(callback) { - self.beforeArt(); - callback(null); + self.beforeArt(callback); }, function displayMenuArt(callback) { if(_.isString(self.menuConfig.art)) { @@ -247,7 +246,7 @@ MenuModule.prototype.leave = function() { this.detachViewControllers(); }; -MenuModule.prototype.beforeArt = function() { +MenuModule.prototype.beforeArt = function(cb) { if(this.cls) { this.client.term.write(ansi.resetScreen()); } @@ -255,6 +254,8 @@ MenuModule.prototype.beforeArt = function() { if(_.isNumber(this.menuConfig.options.baudRate)) { this.client.term.write(ansi.setEmulatedBaudRate(this.menuConfig.options.baudRate)); } + + return cb(null); }; MenuModule.prototype.mciReady = function(mciData, cb) {