Fix xep-0050 stanza

broken in 3a9b45e4f2
This commit is contained in:
mathieui 2016-09-20 20:51:21 +02:00
parent 28f84ab3d9
commit 2586abc0d3

View File

@ -136,7 +136,7 @@ class Command(ElementBase):
('error', 'The command ran, but had errors')] ('error', 'The command ran, but had errors')]
""" """
notes = [] notes = []
notes_xml = self.findall('{%s}note' % self.namespace) notes_xml = self.xml.findall('{%s}note' % self.namespace)
for note in notes_xml: for note in notes_xml:
notes.append((note.attrib.get('type', 'info'), notes.append((note.attrib.get('type', 'info'),
note.text)) note.text))
@ -167,7 +167,7 @@ class Command(ElementBase):
""" """
Remove all notes associated with the command result. Remove all notes associated with the command result.
""" """
notes_xml = self.findall('{%s}note' % self.namespace) notes_xml = self.xml.findall('{%s}note' % self.namespace)
for note in notes_xml: for note in notes_xml:
self.xml.remove(note) self.xml.remove(note)