From 8b9b0d358256015afd0d293ad29f213f5ac663bd Mon Sep 17 00:00:00 2001 From: Erich Gamma Date: Wed, 30 May 2018 17:30:47 +0200 Subject: [PATCH] Fix for #50792: empty pre post scripts not rendered properly --- extensions/npm/src/tasks.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/extensions/npm/src/tasks.ts b/extensions/npm/src/tasks.ts index 63cd80a140943..9022bdf53e74d 100644 --- a/extensions/npm/src/tasks.ts +++ b/extensions/npm/src/tasks.ts @@ -58,7 +58,7 @@ function getPrePostScripts(scripts: any): Set { const script = keys[i]; const prepost = ['pre' + script, 'post' + script]; prepost.forEach(each => { - if (scripts[each]) { + if (scripts[each] !== undefined) { prePostScripts.add(each); } });