update xml writing