partial fix to poorly formatted xml output

I write partial because the opening tag is still not indented for some reason. although readability is much better now.