The logic for processing actions (normally, not in undo mode) was such pending actions were being tested for completeness and conditionally removed from the array in the same loop, meaning that when 2 or more actions were being processed simultaneously and they both finish in the same frame, only one would be removed, leading to the second action being processed once more than it ought to be.
This changes the logic such that the testing and removing are done in their own respective loops, and also encapsulates this logic in the existing filterInPlace method.
The logic for processing actions (normally, not in undo mode) was such pending actions were being tested for completeness and conditionally removed from the array in the same loop, meaning that when 2 or more actions were being processed simultaneously and they both finish in the same frame, only one would be removed, leading to the second action being processed once more than it ought to be.
This changes the logic such that the testing and removing are done in their own respective loops, and also encapsulates this logic in the existing
filterInPlace
method.