If you keep getting the error, consider debugging the javascript action itself.
Easiest way to do that is to simply add the statement:
debugger;
to your javascript code.
Then the code will be halted in your browser at that point and you'll be able to inspect the parameters and see which one is possibly undefined.
Hi, it goes to the nanoflow and the parameters are present but then it crashes on the first action in the nanoflow (and that is just a create variable).