diff --git a/graph_node_renderer/variable_viewer.gd b/graph_node_renderer/variable_viewer.gd index 2cf5148..4aa44a4 100644 --- a/graph_node_renderer/variable_viewer.gd +++ b/graph_node_renderer/variable_viewer.gd @@ -130,7 +130,14 @@ func add_item(item_name: String, item_value: Variant, parent: TreeItem = root, c var item := variable_tree.create_item(parent) item.set_text(0, item_name) - var type: DeckType.Types = DeckType.INVERSE_GODOT_TYPES_MAP[typeof(item_value)] + # TODO: proper null handling + var value_type := typeof(item_value) + var type: DeckType.Types + if value_type == TYPE_NIL: + type = DeckType.Types.STRING + item_value = "" + else: + type = DeckType.INVERSE_GODOT_TYPES_MAP[typeof(item_value)] item.set_meta(&"container", container) item.set_meta(&"indexed", indexed)