added undefined placeholder to force returning undefined...

Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
Alex A. Naanou 2016-09-26 23:45:26 +03:00
parent 79cd6bef51
commit ed98d85724
2 changed files with 7 additions and 1 deletions

View File

@ -15,6 +15,9 @@ var object = require('ig-object')
var args2array = function(a){ return [].slice.call(a) }
var UNDEFINED =
module.UNDEFINED = ['undefined placeholder']
/*********************************************************************/
@ -457,6 +460,8 @@ Action.prototype.pre = function(context, args){
a.post = res
// reset the result...
// NOTE: this is the only difference between this
// and wrapper stages...
res = context
}
}
@ -465,6 +470,7 @@ Action.prototype.pre = function(context, args){
// return context if nothing specific is returned...
res = res === undefined ? context : res
res = res === UNDEFINED ? undefined : res
return {
arguments: args,

View File

@ -1,6 +1,6 @@
{
"name": "ig-actions",
"version": "1.1.0",
"version": "1.2.0",
"description": "",
"main": "actions.js",
"scripts": {