Style point: braces for the ```if/else``` and ```foreach``` statements, space after ```foreach```.  Again, this shows up in a few different places in code.