core, plugins: fixed bad use of children instead of elements() for domish.Element instances.
This commit is contained in:
parent
58561b8732
commit
eb60e0ff33
1 changed files with 19 additions and 19 deletions
|
|
@ -85,8 +85,8 @@ class XEP_0277(object):
|
|||
@param item: domish.Element of microblog item
|
||||
@return: microblog data (dictionary)"""
|
||||
try:
|
||||
entry_elt = filter(lambda x: x.name == "entry", item.children)[0]
|
||||
except KeyError:
|
||||
entry_elt = [child for child in item.elements() if child.name == "entry"][0]
|
||||
except IndexError:
|
||||
warning(_('No entry element in microblog item'))
|
||||
return
|
||||
_entry = atom.Entry().import_xml(entry_elt.toXml().encode('utf-8'))
|
||||
|
|
|
|||
Loading…
Reference in a new issue