registerOnBeforeSubmit adds the same doBeforeSubmit function multiple times
We've got a customized version of the multiselect control. As part of that, we have added a line to register the doBeforeSubmit function via registerOnBeforeSubmit.
I noticed that the doBeforeSubmit function is being called multiple times depending on how many times I've refreshed the screen. I checked via the console if the contextObjects are equivalent and it comes up false. However, the contextObjects entries attributes (prototype, _handle, _select and _startingLength) are equal.
Do you know if there's a fix for this?
This is the code for the multiselect where registerOnBeforeSubmit is being called. It is really the same as the original one in pega_ui_multiselect.js
May be you can try deploying Hfix-5459 and check the behavior.Please contact Global Customer Support for that fix.
However, let me remind a HFIX will address only the issue present in an out of the box final rules. If you have made any customization extending the OOTB files then you have to change your design accordingly in order to fix the issue.