fixing return value of DOMParser.parseFromString