Please also adapt the loop in acceptPosition to "for (i=0; i < myArray.length; i++){}" instead of the for-in which still mentions some filterName.
(moved over from commit comment)