fix rotate bug.