fixes #517