Bugfix: reset current input in loops in order to inputFilter works as
expected in each iteration