Fixing issues with rotation