summaryrefslogtreecommitdiff
path: root/core/io
diff options
context:
space:
mode:
Diffstat (limited to 'core/io')
-rw-r--r--core/io/config_file.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/core/io/config_file.cpp b/core/io/config_file.cpp
index 49fa73dab2..33f992e153 100644
--- a/core/io/config_file.cpp
+++ b/core/io/config_file.cpp
@@ -183,7 +183,9 @@ Error ConfigFile::_internal_save(FileAccess *file) {
if (E != values.front()) {
file->store_string("\n");
}
- file->store_string("[" + E.key() + "]\n\n");
+ if (E.key() != "") {
+ file->store_string("[" + E.key() + "]\n\n");
+ }
for (OrderedHashMap<String, Variant>::Element F = E.get().front(); F; F = F.next()) {
String vstr;