fixes #770