used delegation to bind event to delete button