Change while loop with foreach
fix TYOP
Merge pull request #29 from acidvertigo/patch-29

Change while loop with foreach