From 75343d4bd197fe8f818208de99799d571834def4 Mon Sep 17 00:00:00 2001 From: "Alex A. Naanou" Date: Sun, 18 Feb 2018 13:24:20 +0300 Subject: [PATCH] a minor convenience... Signed-off-by: Alex A. Naanou --- actions.js | 5 +++++ package.json | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/actions.js b/actions.js index fa7e8f5..63a9105 100755 --- a/actions.js +++ b/actions.js @@ -757,6 +757,11 @@ Action.prototype.pre = function(context, args){ // return context if nothing specific is returned... res = res === undefined ? context : res === UNDEFINED ? undefined + // returning an explicit [undefined]... (XXX EXPERIMENTAL) + : res instanceof Array + && res.length == 1 + && res.indexOf(undefined) == 0 ? + undefined : res return { diff --git a/package.json b/package.json index c1a92fc..a167a5f 100755 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "ig-actions", - "version": "3.16.0", + "version": "3.17.0", "description": "", "main": "actions.js", "scripts": {