From 5adaf1c3e73ab328a32deb1efe666aa3b91667b5 Mon Sep 17 00:00:00 2001 From: Haoyu Xu Date: Sun, 5 Feb 2023 21:37:45 -0500 Subject: [PATCH] fix(charword_table): use ref to acquire voice data from alternativeId --- libs/charword_table.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/libs/charword_table.js b/libs/charword_table.js index bba9735..f4a63d8 100644 --- a/libs/charword_table.js +++ b/libs/charword_table.js @@ -31,9 +31,10 @@ export default class CharwordTable { } lookup(operatorName) { + const operatorBlock = this.#charwordTable.operators[this.#getOperatorId(__config.operators[operatorName])] return { config: this.#charwordTable.config, - operator: this.#charwordTable.operators[this.#getOperatorId(__config.operators[operatorName])], + operator: operatorBlock.voice[DEFAULT_REGION][0].ref ? this.#charwordTable.operators[operatorBlock.alternativeId] : operatorBlock, } }