summaryrefslogtreecommitdiff
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 4394e172..22c5022f 100644
--- a/ext/bg/js/translator.js
+++ b/ext/bg/js/translator.js
@@ -113,15 +113,15 @@ class Translator {
expression: expression,
reading: reading,
termTags: dictTagsSort(tags),
- jmdictTermFrequency: (tags => {
- if (tags.has('P')) {
+ termFrequency: (score => {
+ if (score > 0) {
return 'popular';
- } else if (dictJmdictTermTagsRare(tags)) {
+ } else if (score < 0) {
return 'rare';
} else {
return 'normal';
}
- })(result.expressions.get(expression).get(reading))
+ })(dictTermTagScore(result.expressions.get(expression).get(reading)))
});
}
}