Addresses #315

Also a little bit of formatting.
Merge pull request #332 from LightGuard/issue_315

Addresses #315