Skip to content

Commit

Permalink
Skip recovery saving if there's only 1 node
Browse files Browse the repository at this point in the history
  • Loading branch information
RodZill4 committed Jan 22, 2023
1 parent e8da8ac commit bd5ba8a
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions material_maker/panels/graph_edit/graph_edit.gd
Original file line number Diff line number Diff line change
Expand Up @@ -388,6 +388,9 @@ func clear_view() -> void:
func crash_recovery_save() -> void:
if !need_save_crash_recovery:
return
# don't save if there's only a single node
if top_generator.get_child_count() < 2:
return
if save_crash_recovery_path == "":
var dir : Directory = Directory.new()
dir.make_dir_recursive("user://unsaved_projects")
Expand Down

0 comments on commit bd5ba8a

Please sign in to comment.