some fixes
Merge pull request #1 from Napolskih/master

some fixes