Added edit item function.