fixes #1777