remove redundant xml code