From 35c157f9d8c9bb2f59d17ec68b771ffcffb7931d Mon Sep 17 00:00:00 2001 From: Nathan Fritz Date: Sun, 18 Apr 2010 21:16:47 -0700 Subject: [PATCH] changed_status event now happens with got_offline/got_online events --- sleekxmpp/basexmpp.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sleekxmpp/basexmpp.py b/sleekxmpp/basexmpp.py index 1ed9b3c..cc0f108 100644 --- a/sleekxmpp/basexmpp.py +++ b/sleekxmpp/basexmpp.py @@ -271,6 +271,7 @@ class basexmpp(object): name = self.roster[jid].get('name', '') if wasoffline and (show == 'available' or show in presence.showtypes): self.event("got_online", presence) + self.event("changed_status", presence) elif show == 'unavailable': logging.debug("%s %s got offline" % (jid, resource)) if len(self.roster[jid]['presence']) > 1: @@ -278,6 +279,7 @@ class basexmpp(object): else: del self.roster[jid] self.event("got_offline", presence) + self.event("changed_status", presence) elif oldroster != self.roster.get(jid, {'presence': {}})['presence'].get(resource, {}): self.event("changed_status", presence) name = ''