From 8f041da307c0026c72ad958202b549cbfb2eea0b Mon Sep 17 00:00:00 2001 From: Bryan Roe Date: Fri, 10 Jan 2020 15:04:03 -0800 Subject: [PATCH] Updated 'ps' console command to put user name in second column --- agents/meshcore.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/agents/meshcore.js b/agents/meshcore.js index 97100784..b099ee69 100644 --- a/agents/meshcore.js +++ b/agents/meshcore.js @@ -2173,9 +2173,10 @@ function createMeshCore(agent) { break; } case 'ps': { - processManager.getProcesses(function (plist) { + processManager.getProcesses(function (plist) + { var x = ''; - for (var i in plist) { x += i + ', ' + plist[i].cmd + ((plist[i].user) ? (', ' + plist[i].user) : '') + '\r\n'; } + for (var i in plist) { x += i + ((plist[i].user) ? (', ' + plist[i].user) : '') + ', ' + plist[i].cmd + '\r\n'; } sendConsoleText(x, sessionid); }); break;