Cleaned up foreach loop

Don't know what the index variable was doing there, but it was unneeded.