Added edit button function