From 71dcc498bc2395de0f2b4c8d734917bdba698feb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Philipp=20H=C3=B6rist?= Date: Sat, 17 Aug 2019 13:53:19 +0200 Subject: [whiteboard] Remove not used Base objects --- whiteboard/plugin.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/whiteboard/plugin.py b/whiteboard/plugin.py index e07ebd6..e28236f 100644 --- a/whiteboard/plugin.py +++ b/whiteboard/plugin.py @@ -101,6 +101,10 @@ class WhiteboardPlugin(GajimPlugin): @log_calls('WhiteboardPlugin') def connect_with_chat_control(self, control): + for base in self.controls: + if base.chat_control == control: + self.controls.remove(base) + if isinstance(control, chat_control.ChatControl): base = Base(self, control) self.controls.append(base) -- cgit v1.2.3