Fixed the bug with edit button and also the roation bug