]> git.aero2k.de Git - urlbot-v3.git/commitdiff
fix meta plugin
authorThorsten <mail@aero2k.de>
Sat, 24 Jun 2023 19:01:01 +0000 (21:01 +0200)
committerThorsten <mail@aero2k.de>
Sat, 24 Jun 2023 19:01:01 +0000 (21:01 +0200)
distbot/plugins/plugin_help.py

index fd5aad1935e11ea344726dcb0a1a40414cf09e5a..7974454b56a7878191a9650c73e8dc7bb2bf920a 100644 (file)
@@ -28,16 +28,13 @@ class Plugins(Worker):
     plugin_storage = {}
     reverse_lookup = {}
 
-    def __init__(self, actionqueue, queue=""):
-        super(Plugins, self).__init__(actionqueue, queue)
+    def init_channel(self):
+        super().init_channel()
         self.channel.exchange_declare(exchange='plugin_exc', exchange_type='fanout')
-
-    def run(self):
         result = self.channel.queue_declare(exclusive=True, queue=self.queue)
         plugin_queue = result.method.queue
         self.channel.queue_bind(exchange='plugin_exc', queue=plugin_queue)
         self.channel.basic_consume(queue='plugin_registry', on_message_callback=self.callback_plugins)
-        super(Plugins, self).run()
 
     def callback_plugins(self, ch, method, properties, body):
         body = json.loads(body.decode("utf-8"))