Fixes orientation-switch crash