A platform for community discussion. Free, open, simple.
FIX: Don't throw errors on duplicate keys in Yaml
Robin Ward9123f471e862
diff --git a/app/assets/javascripts/discourse/lib/translation-plugin.js b/app/assets/javascripts/discourse/lib/translation-plugin.jsindex 09c0e8b84d3..a8551d0b9ee 100644--- a/app/assets/javascripts/discourse/lib/translation-plugin.js+++ b/app/assets/javascripts/discourse/lib/translation-plugin.js@@ -51,7 +51,7 @@ class TranslationPlugin extends Plugin {this.inputPaths.forEach((path) => {let file = path + "/" + this.inputFile;let yaml = fs.readFileSync(file, { encoding: "UTF-8" });- let loaded = Yaml.load(yaml);+ let loaded = Yaml.load(yaml, { json: true });parsed = deepmerge(parsed, loaded);});