fixes #1299