Prevented concurrent collection modification in InputController.

Erroneous fix last time.