diff src/twisted/plugins/pubsub.py @ 375:9a787881b824

implemented Order-By ProtoXEP (MAM + PubSub)
author Goffi <goffi@goffi.org>
date Sun, 06 Jan 2019 17:29:50 +0100
parents dabee42494ac
children e81964db3cd6
line wrap: on
line diff
--- a/src/twisted/plugins/pubsub.py	Thu Jan 03 20:31:03 2019 +0100
+++ b/src/twisted/plugins/pubsub.py	Sun Jan 06 17:29:50 2019 +0100
@@ -69,7 +69,7 @@
 
 from sat_pubsub import const
 from sat_pubsub import mam as pubsub_mam
-from sat_pubsub.backend import BackendService
+from sat_pubsub.backend import BackendService, ExtraDiscoHandler
 from sat_pubsub.schema import SchemaHandler
 from sat_pubsub.privilege import PrivilegesHandler
 from sat_pubsub.delegation import DelegationsHandler
@@ -231,6 +231,13 @@
         sh = SchemaHandler()
         sh.setHandlerParent(cs)
 
+        # wokkel.pubsub doesn't handle non pubsub# disco
+        # and we need to announce other feature, so this is a workaround
+        # to add them
+        # FIXME: propose a patch upstream to fix this situation
+        ed = ExtraDiscoHandler()
+        ed.setHandlerParent(cs)
+
         # XXX: delegation must be instancied at the end,
         #      because it does some MonkeyPatching on handlers
         dh = DelegationsHandler()