Mercurial > libervia-backend
diff src/core/xmpp.py @ 484:23cbdf0a0777
core: presence status + last resource refactored and kept in entitiesCache in memory.py, profile cache is purged on disconnection
author | Goffi <goffi@goffi.org> |
---|---|
date | Wed, 15 Aug 2012 15:50:46 +0200 |
parents | 2a072735e459 |
children | e789917fb59d |
line wrap: on
line diff
--- a/src/core/xmpp.py Thu Aug 02 01:08:51 2012 +0200 +++ b/src/core/xmpp.py Wed Aug 15 15:50:46 2012 +0200 @@ -249,7 +249,7 @@ statuses["default"] = statuses[None] del statuses[None] - self.host.memory.addPresenceStatus(entity, show or "", + self.host.memory.setPresenceStatus(entity, show or "", int(priority), statuses, self.parent.profile) #now it's time to notify frontends @@ -265,7 +265,7 @@ if statuses.has_key(None): #we only want string keys statuses["default"] = statuses[None] del statuses[None] - self.host.memory.addPresenceStatus(entity, "unavailable", 0, statuses, self.parent.profile) + self.host.memory.setPresenceStatus(entity, "unavailable", 0, statuses, self.parent.profile) #now it's time to notify frontends self.host.bridge.presenceUpdate(entity.full(), "unavailable", 0, statuses, self.parent.profile)