fixes #518