fixes #1252