Commits

Alexander Herrmann committed 19b3e22

fixed xml parsing

  • Participants
  • Parent commits f67e543

Comments (0)

Files changed (1)

piston/emitters.py

     
     @staticmethod
     def parse_xml(xml):
-        return xml2dict.fromstring(xml)['resources']
+        dict = xml2dict.fromstring(xml)
+        # there is only one first node
+        return dict[dict.keys()[0]]
 
 Emitter.register('xml', XMLEmitter, 'text/xml; charset=utf-8')
 if xml2dict: # if import was successfull