XML parsing was moved in a separate method