changeset 58:3e2e0040e3e0

Return support for the pubsub#subscribe feature.
author Ralph Meijer <ralphm@ik.nu>
date Sat, 06 Nov 2004 16:02:32 +0000
parents 445a61f872b6
children 0fa161c00ed9
files idavoll/pubsub.py
diffstat 1 files changed, 8 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/idavoll/pubsub.py	Fri Nov 05 17:15:50 2004 +0000
+++ b/idavoll/pubsub.py	Sat Nov 06 16:02:32 2004 +0000
@@ -197,6 +197,14 @@
         xmlstream.addObserver(PUBSUB_UNSUBSCRIBE, self.onUnsubscribe)
         xmlstream.addObserver(PUBSUB_OPTIONS_GET, self.onOptionsGet)
         xmlstream.addObserver(PUBSUB_OPTIONS_SET, self.onOptionsSet)
+    
+    def getFeatures(self, node):
+        features = []
+
+        if not node:
+            features.append(NS_PUBSUB + "#subscribe")
+
+        return features
 
     def onSubscribe(self, iq):
         self.handler_wrapper(self._onSubscribe, iq)