code cleanup
Merge pull request #40 from snordt/master

code cleanup