« get me outta code hell

hsmusic-wiki - HSMusic - static wiki software cataloguing collaborative creation
about summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/data/language.js6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/data/language.js b/src/data/language.js
index a149e19f..f91e123d 100644
--- a/src/data/language.js
+++ b/src/data/language.js
@@ -110,6 +110,12 @@ export function unflattenLanguageSpec(flat, reference) {
         return {[firstKey]: result};
       }
 
+      const resultKeys = Object.keys(result);
+      if (resultKeys.length === 1 && resultKeys[0] === '_') {
+        delete ownNode[firstKey];
+        return {[firstKey]: result._};
+      }
+
       if (refKeys.length > 1) {
         return withEntries(result, entries =>
           entries.map(([key, value]) => [`${firstKey}.${key}`, value]));