fixed small error checking missing in createViolationsFromXml: (xml).