Fixes #1267