fixes #1779