Skip to content

Commit

Permalink
Fix rare crash when hiding markers
Browse files Browse the repository at this point in the history
  • Loading branch information
rainbowism committed Nov 19, 2020
1 parent 640ce72 commit 1b6af07
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/Util.gd
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,8 @@ func add_hidden(node: Node) -> void:
if len(nodes_hidden) > 10:
var to_delete = nodes_hidden[0]
nodes_hidden.erase(to_delete)
to_delete.queue_free()
if is_instance_valid(to_delete):
to_delete.queue_free()
Events.emit_signal("entrances_changed", -1)

func _on_mode_changed(new_mode: int) -> void:
Expand Down

0 comments on commit 1b6af07

Please sign in to comment.