From e8a3e92ceb17d57ae95efd2a3fe7ed82c6ce2a2f Mon Sep 17 00:00:00 2001 From: Lance Stout Date: Tue, 10 Jul 2012 01:37:44 -0700 Subject: Update plugins to use session_bind handler for disco, and use plugin_end --- sleekxmpp/plugins/xep_0066/oob.py | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'sleekxmpp/plugins/xep_0066/oob.py') diff --git a/sleekxmpp/plugins/xep_0066/oob.py b/sleekxmpp/plugins/xep_0066/oob.py index dc215e83..959c15a2 100644 --- a/sleekxmpp/plugins/xep_0066/oob.py +++ b/sleekxmpp/plugins/xep_0066/oob.py @@ -62,6 +62,12 @@ class XEP_0066(BasePlugin): StanzaPath('iq@type=set/oob_transfer'), self._handle_transfer)) + def plugin_end(self): + self.xmpp.remove_handler('OOB Transfer') + self.xmpp['xep_0030'].del_feature(feature=stanza.OOBTransfer.namespace) + self.xmpp['xep_0030'].del_feature(feature=stanza.OOB.namespace) + + def session_bind(self, jid): self.xmpp['xep_0030'].add_feature(stanza.OOBTransfer.namespace) self.xmpp['xep_0030'].add_feature(stanza.OOB.namespace) -- cgit v1.2.3