NullReferenceException when trying to load XML

I can’t figure out why this is throwing a NullReferenceException when I attach it to a gameobject.Any Help would be greatly appreciated.

enter code here
var available_Units : Array = Array();
var unitList : Array = Array();
private var UNIT_DATA : String = "unitData.xml";

function Start(){
LoadUnitsToArray();
}

function LoadUnitStats(unitID){
    var asset : TextAsset = Resources.Load(UNIT_DATA);
    var xmldoc : XmlDocument = XmlDocument();
    xmldoc.LoadXml(asset.text);	
    var statArray = Array();
    var SEARCH_STRING : String = "/player/unit[@id = '" + unitID + "']";

    if (xmldoc != null){
        var unit : XmlNode = xmldoc.SelectSingleNode(SEARCH_STRING);
        var unitAttrib : XmlNodeList = unit.ChildNodes;
        for(var i in unitAttrib){
	        statArray.Add(i.FirstChild.InnerText);
        }
    }
    else
    Debug.LogError("No XML data File Found");
    return statArray;
}

function LoadUnitsToArray(){
    var asset : TextAsset = Resources.Load(UNIT_DATA);
    var xmldoc : XmlDocument = XmlDocument();
    xmldoc.LoadXml(asset.text);
    var allUnits = xmldoc.GetElementsByTagName("unit");
    if (xmldoc !=null){
        for (var i in allUnits){
            var baseUnitStats : Array = LoadUnitStats(i);
            available_Units.Add(baseUnitStats);
        }
    }

}

From syclamoth: “strip the “.xml” extension from the end there”