From f24df1951a83118f6cea12f11826a88c80aedcc5 Mon Sep 17 00:00:00 2001 From: "Alex A. Naanou" Date: Mon, 16 May 2016 02:26:51 +0300 Subject: [PATCH] minor fix... Signed-off-by: Alex A. Naanou --- ui (gen4)/lib/actions.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/ui (gen4)/lib/actions.js b/ui (gen4)/lib/actions.js index 26e7e141..32f2722d 100755 --- a/ui (gen4)/lib/actions.js +++ b/ui (gen4)/lib/actions.js @@ -401,6 +401,10 @@ Action.prototype.__proto__ = Function // .post(context, data) // -> result // +// +// NOTE: All the defaults should be handled by the pre stage, post will +// process data assuming that it is correct. +// // XXX revise the structure.... // ...is it a better idea to define action methods in an object // and assign that??? @@ -485,7 +489,7 @@ Action.prototype.pre = function(context, args){ } } Action.prototype.post = function(context, data){ - var res = data.result || context + var res = data.result var args = data.arguments || [] // the post handlers get the result as the first argument...