Fixes #1265