fixing some checks in the XML Datasource