aboutsummaryrefslogtreecommitdiff
path: root/ext/bg/js/translator.js
diff options
context:
space:
mode:
Diffstat (limited to 'ext/bg/js/translator.js')
-rw-r--r--ext/bg/js/translator.js8
1 files changed, 4 insertions, 4 deletions
diff --git a/ext/bg/js/translator.js b/ext/bg/js/translator.js
index 99147618..5de99e8e 100644
--- a/ext/bg/js/translator.js
+++ b/ext/bg/js/translator.js
@@ -60,7 +60,7 @@ class Translator {
let definitions = [];
for (const deinflection of deinflections) {
for (const definition of deinflection.definitions) {
- const tags = await this.buildTags(definition.tags, titles);
+ const tags = await this.buildTags(definition.tags, definition.dictionary);
tags.push(dictTagBuildSource(definition.dictionary));
let frequencies = await this.database.findTermFreq(definition.expression, titles);
@@ -124,7 +124,7 @@ class Translator {
}
for (const definition of definitions) {
- const tags = await this.buildTags(definition.tags, titles);
+ const tags = await this.buildTags(definition.tags, definition.dictionary);
tags.push(dictTagBuildSource(definition.dictionary));
definition.tags = dictTagsSort(tags);
@@ -134,10 +134,10 @@ class Translator {
return definitions;
}
- async buildTags(names, titles) {
+ async buildTags(names, title) {
const results = [];
for (const name of names) {
- const meta = await this.database.findTag(name.split(':')[0], titles);
+ const meta = await this.database.findTag(name.split(':')[0], title);
const result = {name};
for (const prop in meta || {}) {