diff --git a/demo-workflows/workflows/Device_memory_monitoring.json b/demo-workflows/workflows/Device_memory_monitoring.json index 1c10164..a7e1c16 100644 --- a/demo-workflows/workflows/Device_memory_monitoring.json +++ b/demo-workflows/workflows/Device_memory_monitoring.json @@ -77,7 +77,7 @@ "inputParameters": { "lambdaValue": "${Netconf_read_structured_device_dataRefName_EZW5.output.response_body.memory-summary.nodes.node}", "iterator": "${LoopTask.output.iteration}", - "scriptExpression": "if($.iterator == null){\n return $.lambdaValue[0]\n} else {\n return $.lambdaValue[$.iterator];\n}" + "scriptExpression": "return $.lambdaValue[($.iterator-1).toString()]" }, "type": "LAMBDA", "decisionCases": {}, diff --git a/demo-workflows/workflows/Install_all_from_inventory.json b/demo-workflows/workflows/Install_all_from_inventory.json index 157d2e4..e0a6282 100644 --- a/demo-workflows/workflows/Install_all_from_inventory.json +++ b/demo-workflows/workflows/Install_all_from_inventory.json @@ -44,7 +44,7 @@ "inputParameters": { "lambdaValue": "${INVENTORY_get_pages_cursorsRefName_iHgJ.output.page_ids}", "iterator": "${LoopTask.output.iteration}", - "scriptExpression": "if($.iterator == null){\n return $.lambdaValue[\"0\"]\n} else {\n return $.lambdaValue[$.iterator.toString()];\n}" + "scriptExpression": "return $.lambdaValue[($.iterator-1).toString()]" }, "type": "LAMBDA", "decisionCases": {}, diff --git a/demo-workflows/workflows/Uninstall_all_from_inventory.json b/demo-workflows/workflows/Uninstall_all_from_inventory.json index 22701d3..ffc73b3 100644 --- a/demo-workflows/workflows/Uninstall_all_from_inventory.json +++ b/demo-workflows/workflows/Uninstall_all_from_inventory.json @@ -44,7 +44,7 @@ "inputParameters": { "lambdaValue": "${INVENTORY_get_pages_cursorsRefName_iHgJ.output.page_ids}", "iterator": "${LoopTask.output.iteration}", - "scriptExpression": "if($.iterator == null){\n return $.lambdaValue[\"0\"]\n} else {\n return $.lambdaValue[$.iterator.toString()];\n}" + "scriptExpression": "return $.lambdaValue[($.iterator-1).toString()]" }, "type": "LAMBDA", "decisionCases": {},