summaryrefslogtreecommitdiff
path: root/sleekxmpp/componentxmpp.py
diff options
context:
space:
mode:
authorNathan Fritz <nathan@andyet.net>2011-04-14 16:27:27 -0700
committerNathan Fritz <nathan@andyet.net>2011-04-14 16:27:27 -0700
commit46dc6eac887907109c97fc218498bcc894756659 (patch)
treeadf05107e0cdf828443b470a233bc36c19678a4d /sleekxmpp/componentxmpp.py
parentb9bf30e095da565f02f3ed20dab6b378dba4ab7d (diff)
downloadslixmpp-46dc6eac887907109c97fc218498bcc894756659.tar.gz
slixmpp-46dc6eac887907109c97fc218498bcc894756659.tar.bz2
slixmpp-46dc6eac887907109c97fc218498bcc894756659.tar.xz
slixmpp-46dc6eac887907109c97fc218498bcc894756659.zip
remove roster item state responsibility from clients
Diffstat (limited to 'sleekxmpp/componentxmpp.py')
-rw-r--r--sleekxmpp/componentxmpp.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/sleekxmpp/componentxmpp.py b/sleekxmpp/componentxmpp.py
index 0963c502..121e7c85 100644
--- a/sleekxmpp/componentxmpp.py
+++ b/sleekxmpp/componentxmpp.py
@@ -78,6 +78,8 @@ class ComponentXMPP(BaseXMPP):
Callback('Handshake',
MatchXPath('{jabber:component:accept}handshake'),
self._handle_handshake))
+ self.add_event_handler('presence_probe',
+ self._handle_probe)
def connect(self):
"""
@@ -139,3 +141,8 @@ class ComponentXMPP(BaseXMPP):
xml -- The reply handshake stanza.
"""
self.event("session_start")
+
+ def _handle_probe(self, presence):
+ pto = presence['to'].bare
+ pfrom = presence['from'].bare
+ self.roster[pto][pfrom].handle_probe(presence)