From 8aa3d0c0476d3a704069d324c03d2703e5e2ad76 Mon Sep 17 00:00:00 2001 From: Lance Stout Date: Sun, 24 Oct 2010 18:56:50 -0400 Subject: Fixed got_offline triggering bug. --- sleekxmpp/basexmpp.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/sleekxmpp/basexmpp.py b/sleekxmpp/basexmpp.py index 4ec0ac2a..bef4711e 100644 --- a/sleekxmpp/basexmpp.py +++ b/sleekxmpp/basexmpp.py @@ -593,8 +593,9 @@ class BaseXMPP(XMLStream): if not connections and not self.roster[jid]['in_roster']: del self.roster[jid] - self.event("got_offline", presence) - if was_offline: + if not was_offline: + self.event("got_offline", presence) + else: return False name = '(%s) ' % name if name else '' -- cgit v1.2.3