Prevent autoloads from being added or removed twice
This commit is contained in:
parent
0a420c4787
commit
c4c4da77b1
1 changed files with 0 additions and 8 deletions
|
@ -529,8 +529,6 @@ void EditorAutoloadSettings::update_autoload() {
|
|||
info.node->queue_delete();
|
||||
info.node = nullptr;
|
||||
}
|
||||
|
||||
ProjectSettings::get_singleton()->remove_autoload(info.name);
|
||||
}
|
||||
|
||||
// Load new/changed autoloads
|
||||
|
@ -555,12 +553,6 @@ void EditorAutoloadSettings::update_autoload() {
|
|||
}
|
||||
}
|
||||
|
||||
ProjectSettings::AutoloadInfo prop_info;
|
||||
prop_info.name = info->name;
|
||||
prop_info.path = info->path;
|
||||
prop_info.is_singleton = info->is_singleton;
|
||||
ProjectSettings::get_singleton()->add_autoload(prop_info);
|
||||
|
||||
if (!info->in_editor && !info->is_singleton) {
|
||||
// No reason to keep this node
|
||||
memdelete(info->node);
|
||||
|
|
Loading…
Reference in a new issue