Fixed foreach loop

Went with @jonathandavis suggestion of combining it into one line. Derp.