quick_frontend: allow presence of entities without resource
This commit is contained in:
parent
edfdc06654
commit
c1c7b0446c
1 changed files with 2 additions and 1 deletions
|
|
@ -471,7 +471,8 @@ class ProfileContactList(object):
|
|||
if not cache[C.CONTACT_RESOURCES]:
|
||||
cache[C.CONTACT_MAIN_RESOURCE] = None
|
||||
else:
|
||||
assert entity.resource
|
||||
if not entity.resource:
|
||||
log.warning(_(u"received presence from entity without resource: {}".format(entity)))
|
||||
resources_data = cache[C.CONTACT_RESOURCES]
|
||||
resource_data = resources_data.setdefault(entity.resource, {})
|
||||
resource_data[C.PRESENCE_SHOW] = show
|
||||
|
|
|
|||
Loading…
Reference in a new issue