summaryrefslogtreecommitdiff
path: root/ext/bg/js
diff options
context:
space:
mode:
Diffstat (limited to 'ext/bg/js')
-rw-r--r--ext/bg/js/options.js17
1 files changed, 17 insertions, 0 deletions
diff --git a/ext/bg/js/options.js b/ext/bg/js/options.js
index f1f6c9a1..ca2792c0 100644
--- a/ext/bg/js/options.js
+++ b/ext/bg/js/options.js
@@ -119,6 +119,23 @@ function optionsVersion(options) {
dictionary.enabled = dictionary.enableTerms || dictionary.enableKanji;
dictionary.priority = 0;
}
+ },
+ () => {
+ const fixupFields = fields => {
+ const fixups = {
+ '{expression-furigana}': '{furigana}',
+ '{glossary-list}': '{glossary}'
+ };
+
+ for (const name in fields) {
+ for (const fixup in fixups) {
+ fields[name] = fields[name].replace(fixup, fixups[fixup]);
+ }
+ }
+ };
+
+ fixupFields(options.anki.terms.fields);
+ fixupFields(options.anki.kanji.fields);
}
];