diff options
author | Alex Yatskov <alex@foosoft.net> | 2016-04-24 18:59:29 -0700 |
---|---|---|
committer | Alex Yatskov <alex@foosoft.net> | 2016-04-24 18:59:29 -0700 |
commit | cac6fc1427106420b28777d94907bf27ab1995a3 (patch) | |
tree | e8ab59bed16d7e2ba1ed887ffb2b9ccee510f9a9 /ext/bg/js/translator.js | |
parent | a192a8d8b549d5979a427d86c51f94bb5f4be907 (diff) |
Basic kanji output
Diffstat (limited to 'ext/bg/js/translator.js')
-rw-r--r-- | ext/bg/js/translator.js | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/ext/bg/js/translator.js b/ext/bg/js/translator.js index 6be80581..606f6ec5 100644 --- a/ext/bg/js/translator.js +++ b/ext/bg/js/translator.js @@ -131,11 +131,11 @@ class Translator { } findKanji(text) { - let results = []; - + let results = []; const processed = {}; + for (const c of text) { - if (!processed.has(c)) { + if (!processed[c]) { results = results.concat(this.dictionary.findKanji(c)); processed[c] = true; } |