code polishing
Merge pull request #293 from nskvortsov/master

code polishing