Fixed errors and added handler

- Added rotation handler
- Fixed wrong imports