mirror of
https://github.com/godotengine/godot.git
synced 2025-10-19 16:03:29 +00:00
Don't write global script class information if there is none
(cherry picked from commit 3163611f0c
)
This commit is contained in:
parent
55d756cbab
commit
fcaf17824f
2 changed files with 10 additions and 2 deletions
|
@ -276,7 +276,11 @@ void ScriptServer::save_global_classes() {
|
|||
gcarr.push_back(d);
|
||||
}
|
||||
|
||||
ProjectSettings::get_singleton()->set("_global_script_classes", gcarr);
|
||||
if (gcarr.empty()) {
|
||||
ProjectSettings::get_singleton()->clear("_global_script_classes");
|
||||
} else {
|
||||
ProjectSettings::get_singleton()->set("_global_script_classes", gcarr);
|
||||
}
|
||||
ProjectSettings::get_singleton()->save();
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue