Fixed a the loop variable