Fixes #1153 but not #1162