fixed bug with error loading xml.