Fix name conventions of some of the foreach loop variables.