fixes #1267