#40 #41 #43 refactor has been started
fixes

issue #40
Merge pull request #44 from TikhomirovSergey/master

#40 fix