summaryrefslogtreecommitdiff
path: root/sleekxmpp/plugins/xep_0060/pubsub.py
diff options
context:
space:
mode:
authorLance Stout <lancestout@gmail.com>2011-09-01 11:30:55 -0700
committerLance Stout <lancestout@gmail.com>2011-09-01 11:30:55 -0700
commitafbd506cfc5aea6e70edc5cb6584e9d36f539965 (patch)
tree7e6b782d26978c61910a00e080ccf42b2c15061a /sleekxmpp/plugins/xep_0060/pubsub.py
parentec01e45ed1f811a88c39f17f92a30f2f225a6ebc (diff)
downloadslixmpp-afbd506cfc5aea6e70edc5cb6584e9d36f539965.tar.gz
slixmpp-afbd506cfc5aea6e70edc5cb6584e9d36f539965.tar.bz2
slixmpp-afbd506cfc5aea6e70edc5cb6584e9d36f539965.tar.xz
slixmpp-afbd506cfc5aea6e70edc5cb6584e9d36f539965.zip
Users can retrieve their affiliations now, with tests.
Diffstat (limited to 'sleekxmpp/plugins/xep_0060/pubsub.py')
-rw-r--r--sleekxmpp/plugins/xep_0060/pubsub.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/sleekxmpp/plugins/xep_0060/pubsub.py b/sleekxmpp/plugins/xep_0060/pubsub.py
index 990e8241..a5db137e 100644
--- a/sleekxmpp/plugins/xep_0060/pubsub.py
+++ b/sleekxmpp/plugins/xep_0060/pubsub.py
@@ -177,6 +177,12 @@ class xep_0060(base_plugin):
iq['pubsub']['subscriptions']['node'] = node
return iq.send(block=block, callback=callback, timeout=timeout)
+ def get_affiliations(self, jid, node=None, ifrom=None, block=True,
+ callback=None, timeout=None):
+ iq = self.xmpp.Iq(sto=jid, sfrom=ifrom, stype='get')
+ iq['pubsub']['affiliations']['node'] = node
+ return iq.send(block=block, callback=callback, timeout=timeout)
+
def get_subscription_options(self, jid, node, user_jid, ifrom=None,
block=True, callback=None, timeout=None):
iq = self.xmpp.Iq(sto=jid, sfrom=ifrom, stype='get')