Converts XML to JSON using node-expat