diff options
author | Paul Joannon <hello@pauljoannon.com> | 2020-05-20 01:03:03 +0200 |
---|---|---|
committer | Paul Joannon <hello@pauljoannon.com> | 2020-05-20 01:04:21 +0200 |
commit | b7a694679013b56b4ffcb9b98b6c8cb2252202cd (patch) | |
tree | 4446a68d5d67ab33b66b1ba0c5cfa5ce9f9c6553 | |
parent | cba1f492cc300bf5686f8ccd7f743bc37635fa54 (diff) |
check the params section exist before erasing it in import_dock
related #38864
-rw-r--r-- | editor/import_dock.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/editor/import_dock.cpp b/editor/import_dock.cpp index 1128b72c5a..8ab2e0aef1 100644 --- a/editor/import_dock.cpp +++ b/editor/import_dock.cpp @@ -441,7 +441,9 @@ void ImportDock::_reimport() { } else { //override entirely config->set_value("remap", "importer", importer_name); - config->erase_section("params"); + if (config->has_section("params")) { + config->erase_section("params"); + } for (List<PropertyInfo>::Element *E = params->properties.front(); E; E = E->next()) { config->set_value("params", E->get().name, params->values[E->get().name]); |