Skip to content
Snippets Groups Projects
Commit f92a971b authored by Anael Beutot's avatar Anael Beutot
Browse files

Fix authentication corner case.

When role changes in a new authentication attempt.
Was missing a method on MainLoop instance to unregister all plugins.
parent e2c637e6
No related branches found
No related tags found
No related merge requests found
...@@ -286,6 +286,11 @@ class MainLoop(object): ...@@ -286,6 +286,11 @@ class MainLoop(object):
plugin.stop() plugin.stop()
def close_plugins(self):
"""Unregister all plugins from the loop."""
for plugin in self.registered_plugins.copy():
self.unregister_plugin(plugin)
def restart_rpc_connection(self, *args): def restart_rpc_connection(self, *args):
if not self.rpc_connected: if not self.rpc_connected:
return return
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment