xep_0045: also return default value when attr doesn't exist
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
This commit is contained in:
parent
200e1a6128
commit
c8d1eaa2dc
1 changed files with 1 additions and 1 deletions
|
@ -29,7 +29,7 @@ class MUCBase(ElementBase):
|
|||
item = self.xml.find(f'{{{NS_USER}}}item')
|
||||
if item is None:
|
||||
return default
|
||||
return item.get(attr)
|
||||
return item.get(attr, default)
|
||||
|
||||
def set_item_attr(self, attr, value: str):
|
||||
item = self.xml.find(f'{{{NS_USER}}}item')
|
||||
|
|
Loading…
Reference in a new issue