Fixes in rotatesnap and snapall functions