Prevents autolayout error

Fixes #2742

/cc @aerych