From 58d707c695ca8c2a0f2cd515555a1e32b51b0b23 Mon Sep 17 00:00:00 2001 From: Relintai Date: Wed, 26 Jan 2022 19:40:36 +0100 Subject: [PATCH] Check whether the the on_visibility changes signal is connected before attempting to connect it in data manager's main panel. --- game/addons/data_manager/panels/MainPanel.gd | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/game/addons/data_manager/panels/MainPanel.gd b/game/addons/data_manager/panels/MainPanel.gd index 4e35e684..66b58447 100644 --- a/game/addons/data_manager/panels/MainPanel.gd +++ b/game/addons/data_manager/panels/MainPanel.gd @@ -22,7 +22,8 @@ var _initialized : bool = false var _plugin : EditorPlugin = null func _enter_tree(): - connect("visibility_changed", self, "on_visibility_changed") + if !is_connected("visibility_changed", self, "on_visibility_changed"): + connect("visibility_changed", self, "on_visibility_changed") func on_visibility_changed(): if _plugin && is_visible_in_tree() && !_initialized: