diff options
Diffstat (limited to 'ext/js/comm')
-rw-r--r-- | ext/js/comm/api.js | 4 | ||||
-rw-r--r-- | ext/js/comm/mecab.js | 8 |
2 files changed, 6 insertions, 6 deletions
diff --git a/ext/js/comm/api.js b/ext/js/comm/api.js index a2eb004c..137cda41 100644 --- a/ext/js/comm/api.js +++ b/ext/js/comm/api.js @@ -68,8 +68,8 @@ class API { return this._invoke('suspendAnkiCardsForNote', {noteId}); } - getExpressionAudioInfoList(source, expression, reading, details) { - return this._invoke('getExpressionAudioInfoList', {source, expression, reading, details}); + getTermAudioInfoList(source, term, reading, details) { + return this._invoke('getTermAudioInfoList', {source, term, reading, details}); } commandExec(command, params) { diff --git a/ext/js/comm/mecab.js b/ext/js/comm/mecab.js index 4eff2927..9a706391 100644 --- a/ext/js/comm/mecab.js +++ b/ext/js/comm/mecab.js @@ -108,7 +108,7 @@ class Mecab { * { * name: (string), * lines: [ - * {expression: (string), reading: (string), source: (string)}, + * {term: (string), reading: (string), source: (string)}, * ... * ] * }, @@ -172,11 +172,11 @@ class Mecab { const lines = []; for (const rawLine of rawLines) { const line = []; - for (let {expression, reading, source} of rawLine) { - if (typeof expression !== 'string') { expression = ''; } + for (let {expression: term, reading, source} of rawLine) { + if (typeof term !== 'string') { term = ''; } if (typeof reading !== 'string') { reading = ''; } if (typeof source !== 'string') { source = ''; } - line.push({expression, reading, source}); + line.push({term, reading, source}); } lines.push(line); } |