Flow Designer - JSON Flow variable array becomes null object when array has no items

Ron28
Kilo Sage

I noticed some strange behaviour with a flow variable of type JSON, that contains an array but then becomes null when all items in the array have been removed. I was expecting it to simply remain an array with length of 0. To illustrate here is a simplified example in flow designer:

FlowDesigner_JSON_Flow_variable.jpg
11 - Array with 2 items
12 - Remove one item from the array - result is still an array
13 - Remove another item from the array - result is no longer an array but a null object
14 - Fails as the flow variable is now a null object, therefore fd_data.flow_var.list.length fails.

Of course there's ways around this and I have my flow working fine, but I wondered if this should be reported as a bug?

Ron

1 ACCEPTED SOLUTION

Ron28
Kilo Sage

Sorry this should have gone to the developers forum.

View solution in original post

1 REPLY 1

Ron28
Kilo Sage

Sorry this should have gone to the developers forum.