From 851048077c3e150be4a1652b4e003c3ee5b4a835 Mon Sep 17 00:00:00 2001 From: Anna Thomas Date: Thu, 4 Dec 2014 13:16:24 +0000 Subject: [PATCH] Remove new lines from version --- red/server.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/red/server.js b/red/server.js index 3952ff71e..b6f37fc58 100644 --- a/red/server.js +++ b/red/server.js @@ -163,8 +163,9 @@ function installModule(module) { } } else { var grandchild = child_process.exec('npm view '+module+' version', function(err, stdin, stdout) { - util.log("[red] Installed module: "+module+":"+stdin); - resolve(redNodes.addModule(module,stdin).then(reportAddedModules)); + var version = stdin.replace(/\s/g, ""); + util.log("[red] Installed module: "+module+":"+version); + resolve(redNodes.addModule(module,version).then(reportAddedModules)); }); } });