From d5ea03171ea997d6734e6d31197c7f233fff7084 Mon Sep 17 00:00:00 2001 From: Alex Yatskov Date: Sun, 11 Sep 2016 12:29:18 -0700 Subject: Working with IndexDb --- ext/bg/js/dictionary.js | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'ext/bg/js/dictionary.js') diff --git a/ext/bg/js/dictionary.js b/ext/bg/js/dictionary.js index 624fe15e..0c5e4c4a 100644 --- a/ext/bg/js/dictionary.js +++ b/ext/bg/js/dictionary.js @@ -59,15 +59,15 @@ class Dictionary { findKanji(kanji) { const results = []; - return this.db.kanji.where('c').equals(kanji).each(row => { + return this.db.kanji.where('character').equals(kanji).each(row => { results.push({ - character: row.c, - onyomi: row.o.split(' '), - kunyomi: row.k.split(' '), - tags: row.t.split(' '), - glossary: row.m + character: row.character, + onyomi: row.onyomi.split(' '), + kunyomi: row.kunyomi.split(' '), + tags: row.tags.split(' '), + glossary: row.meanings }); - }); + }).then(() => results); } getEntities(tags) { -- cgit v1.2.3