fixes #805
Merge pull request #812 from Tjatse/master

fixes #805