I believe the bug is on this line. You've already consumed the parameter at index 0 up on line 70, but then you do list.get(index++). I believe this ought to be list ...
Some results have been hidden because they may be inaccessible to you
Show inaccessible results