added xml check in to edit action