Merge pull request #4 from sergeyt/master

some improvements
Merge remote-tracking branch 'upstream/master'