[BugFix #548]
Merge pull request #824 from MichaelKalygin/bugfix548

[BugFix #548]