From 9f187ed027a7bc97f7fbf36e744e8f09a27e0624 Mon Sep 17 00:00:00 2001 From: Calum Lind Date: Sun, 15 May 2016 19:10:49 +0100 Subject: [PATCH] [WebUI] Add missing deregister event handlers --- deluge/ui/web/json_api.py | 3 +++ deluge/ui/web/pluginmanager.py | 2 ++ 2 files changed, 5 insertions(+) diff --git a/deluge/ui/web/json_api.py b/deluge/ui/web/json_api.py index e369582d1..e3d3b1a33 100644 --- a/deluge/ui/web/json_api.py +++ b/deluge/ui/web/json_api.py @@ -379,6 +379,9 @@ class WebApi(JSONComponent): self.sessionproxy = SessionProxy() def disable(self): + client.deregister_event_handler("PluginEnabledEvent", self._json.get_remote_methods) + client.deregister_event_handler("PluginDisabledEvent", self._json.get_remote_methods) + if client.is_classicmode(): component.get("Web.PluginManager").stop() else: diff --git a/deluge/ui/web/pluginmanager.py b/deluge/ui/web/pluginmanager.py index 751407618..f5485cfea 100644 --- a/deluge/ui/web/pluginmanager.py +++ b/deluge/ui/web/pluginmanager.py @@ -109,6 +109,8 @@ class PluginManager(PluginManagerBase, component.Component): Stop the plugin manager """ self.disable_plugins() + client.deregister_event_handler("PluginEnabledEvent", self._on_plugin_enabled_event) + client.deregister_event_handler("PluginDisabledEvent", self._on_plugin_disabled_event) def update(self): pass