From 4074dd09f63e347982455bd5c66f24f2375f2bb1 Mon Sep 17 00:00:00 2001 From: coderaiser Date: Thu, 30 Jan 2014 11:11:37 -0500 Subject: [PATCH] fix(console) io - > exec --- lib/server/console.js | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/lib/server/console.js b/lib/server/console.js index a776bc25..fc58aa6d 100644 --- a/lib/server/console.js +++ b/lib/server/console.js @@ -109,7 +109,7 @@ */ function getOnMessage(pConnNum, callback) { return function(pCommand) { - var lMsg, lWinCommand, lExec_func, firstChar, + var lWinCommand, lExec_func, firstChar, connName, lError, lRet, lExecSymbols, isContain, dir, options = {}; @@ -169,11 +169,9 @@ pCommand = connName + pCommand; pCommand = Util.addNewLine(pCommand); - lMsg = Util.stringifyJSON({ + Util.exec(callback, { stdout: pCommand }); - - io.sockets.emit('message', lMsg); } else if (WIN32 || firstChar === ' ' || isContain) exec(pCommand, options, lExec_func); else