Fix for #272 bug.
Merge pull request #605 from kvasnyk/master

Fix for #272 bug.