summaryrefslogtreecommitdiff
path: root/ext/bg/js/translator.js
diff options
context:
space:
mode:
authorAlex Yatskov <alex@foosoft.net>2017-09-15 13:32:49 -0700
committerAlex Yatskov <alex@foosoft.net>2017-09-15 13:32:49 -0700
commit7f55f1c8d2b82abda1cbdc353f28ae9136a361f3 (patch)
treea2046d2804015ee71cc9cc2b56d62e59c9e6f78b /ext/bg/js/translator.js
parent39e38d56657b9b11f49af96d84c819e6b6fcec8d (diff)
display term frequencies
Diffstat (limited to 'ext/bg/js/translator.js')
-rw-r--r--ext/bg/js/translator.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/ext/bg/js/translator.js b/ext/bg/js/translator.js
index 0cd49c27..3dd482ca 100644
--- a/ext/bg/js/translator.js
+++ b/ext/bg/js/translator.js
@@ -42,7 +42,7 @@ class Translator {
const definitionsGrouped = dictTermsGroup(definitions, dictionaries);
for (const definition of definitionsGrouped) {
- this.buildTermFrequencies(definition, titles);
+ await this.buildTermFrequencies(definition, titles);
}
return {length, definitions: definitionsGrouped};
@@ -53,7 +53,7 @@ class Translator {
const {length, definitions} = await this.findTerms(text, dictionaries, alphanumeric);
for (const definition of definitions) {
- this.buildTermFrequencies(definition, titles);
+ await this.buildTermFrequencies(definition, titles);
}
return {length, definitions};