1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-04 12:00:25 +00:00

Improve ConfigFile get_sections and get_section_keys by returning Vector<String>

This commit is contained in:
dementive
2025-04-23 23:32:05 -04:00
parent 931820d33c
commit b8e44a0000
20 changed files with 58 additions and 105 deletions

View File

@@ -330,8 +330,7 @@ void EditorExport::load_config() {
String option_section = "preset." + itos(index) + ".options";
List<String> options;
config->get_section_keys(option_section, &options);
Vector<String> options = config->get_section_keys(option_section);
for (const String &E : options) {
Variant value = config->get_value(option_section, E);
@@ -339,8 +338,7 @@ void EditorExport::load_config() {
}
if (credentials->has_section(option_section)) {
options.clear();
credentials->get_section_keys(option_section, &options);
options = credentials->get_section_keys(option_section);
for (const String &E : options) {
// Drop values for secret properties that no longer exist, or during the next save they would end up in the regular config file.