From 8d50e64717d7bfbb24376da09946215287307a4f Mon Sep 17 00:00:00 2001 From: abetomo Date: Tue, 18 Apr 2017 12:36:08 +0900 Subject: [PATCH 1/2] Change the end of sentence to semicolon --- lib/main.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/main.js b/lib/main.js index 1e1eae9e..f26f8892 100644 --- a/lib/main.js +++ b/lib/main.js @@ -362,7 +362,7 @@ Lambda.prototype._readArchive = function (program, archive_callback) { return archive_callback(err); } fs.readFile(program.deployZipfile, archive_callback); -}, +}; Lambda.prototype._archive = function (program, archive_callback) { if (program.deployZipfile && fs.existsSync(program.deployZipfile)) { From 1516b9a6055bd4f7c40647497a94aa5b290ceeb8 Mon Sep 17 00:00:00 2001 From: abetomo Date: Tue, 18 Apr 2017 13:04:16 +0900 Subject: [PATCH 2/2] Fix not to output when there is no element --- lib/main.js | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/lib/main.js b/lib/main.js index f26f8892..ac6851ea 100644 --- a/lib/main.js +++ b/lib/main.js @@ -682,8 +682,15 @@ Lambda.prototype.deploy = function (program) { if (err) { throw err; } - console.log('=> All tasks done. Results follow: '); - console.log(JSON.stringify(results, null, ' ')); + const resultsIsEmpty = results.filter(function(result) { + return result.filter(function(res) { + return res.length > 0; + }).length > 0; + }).length == 0; + if (!resultsIsEmpty) { + console.log('=> All tasks done. Results follow: '); + console.log(JSON.stringify(results, null, ' ')); + } }); }); };