misc changes to logic that hopefully make it more readable
Merge pull request #8 from ekimekim/style

misc changes to logic that hopefully make it more readable