fixed some errors in xml-parsing