This is an automated email from the ASF dual-hosted git repository.
dgrove pushed a commit to branch master
in repository
https://gitbox.apache.org/repos/asf/incubator-openwhisk-composer.git
The following commit(s) were added to refs/heads/master by this push:
new a130762 Fix incorrect path handling in fsm synthesis (#12)
a130762 is described below
commit a1307629a726d5643307a9076645a933b5463093
Author: Olivier Tardieu <[email protected]>
AuthorDate: Wed Nov 28 14:06:55 2018 -0500
Fix incorrect path handling in fsm synthesis (#12)
---
conductor.js | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/conductor.js b/conductor.js
index 0764018..a70f5a7 100644
--- a/conductor.js
+++ b/conductor.js
@@ -153,7 +153,11 @@ function main (composition) {
function compile (parent, node) {
if (arguments.length === 1) return [{ parent, type: 'empty' }]
- if (arguments.length === 2) return
Object.assign(compiler[node.type](node.path || parent, node), { path: node.path
})
+ if (arguments.length === 2) {
+ const fsm = compiler[node.type](node.path || parent, node)
+ if (node.path !== undefined) fsm[0].path = node.path
+ return fsm
+ }
return Array.prototype.slice.call(arguments, 1).reduce((fsm, node) => {
fsm.push(...compile(parent, node)); return fsm }, [])
}