From 64fe001591ed6ccdfb97bc917ecae46639ee8510 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Manuel=20Qui=C3=B1ones?= Date: Wed, 4 Dec 2024 15:16:39 -0300 Subject: [PATCH] Background: Add safety check for parent block Mainly to test the background in isolation in a new Control scene. --- addons/block_code/ui/blocks/utilities/background/background.gd | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/block_code/ui/blocks/utilities/background/background.gd b/addons/block_code/ui/blocks/utilities/background/background.gd index 769185b9..7fc39381 100644 --- a/addons/block_code/ui/blocks/utilities/background/background.gd +++ b/addons/block_code/ui/blocks/utilities/background/background.gd @@ -56,7 +56,7 @@ func _ready(): func _get_border_color() -> Color: - if parent_block.has_focus(): + if parent_block and parent_block.has_focus(): return Constants.FOCUS_BORDER_COLOR return outline_color