Ajax: simplify jQuery.parseXML method

-2 bytes to the gzipped size and code looks a bit nicer

This wasn't landed to the compat branch though, since size would increase
with this cherry-pick

Closes gh-1856