Sfoglia il codice sorgente

tools: avoid null level name

Daniele Bartolini 5 anni fa
parent
commit
a1aac69414
1 ha cambiato i file con 2 aggiunte e 2 eliminazioni
  1. 2 2
      tools/level_editor/level_editor.vala

+ 2 - 2
tools/level_editor/level_editor.vala

@@ -866,7 +866,7 @@ public class LevelEditorApplication : Gtk.Application
 		Gtk.Label label = new Gtk.Label(null);
 		label.set_markup("Data Compiler disconnected.\rTry to <a href=\"restart\">restart</a> compiler to continue.");
 		label.activate_link.connect(() => {
-			restart_backend.begin(_project.source_dir(), _level._name);
+			restart_backend.begin(_project.source_dir(), _level._name != null ? _level._name : "");
 			return true;
 		});
 
@@ -878,7 +878,7 @@ public class LevelEditorApplication : Gtk.Application
 		Gtk.Label label = new Gtk.Label(null);
 		label.set_markup("Data compilation failed.\rFix errors and <a href=\"restart\">restart</a> compiler to continue.");
 		label.activate_link.connect(() => {
-			restart_backend.begin(_project.source_dir(), _level._name);
+			restart_backend.begin(_project.source_dir(), _level._name != null ? _level._name : "");
 			return true;
 		});