def getError(self):
        """ Return the error-condition (if present) or the textual description of the error (otherwise). """
        errtag=self.getTag('error')
        if errtag:
            for tag in errtag.getChildren():
                if tag.getName()<>'text': return tag.getName()
            return errtag.getData()
 Return the error-condition (if present) or the textual description of the error (otherwise). 
chrome-cordova/gcmServer/xmpp/protocol.py