Fix incorrect definitions array being used for compatibility merged definitions (#887)

This commit is contained in:
toasted-nutbread 2020-10-04 22:21:16 -04:00 committed by GitHub
parent 54810510fa
commit 8c8c27001e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -194,12 +194,12 @@ class Translator {
const unusedDefinitions = unsequencedDefinitions.filter((definition) => !usedDefinitions.has(definition));
for (const groupedDefinition of this._groupTerms(unusedDefinitions, enabledDictionaryMap)) {
const {reasons, score, expression, reading, source, rawSource, sourceTerm, dictionary, furiganaSegments, termTags} = groupedDefinition;
const {reasons, score, expression, reading, source, rawSource, sourceTerm, dictionary, furiganaSegments, termTags, definitions: definitions2} = groupedDefinition;
const termDetailsList = [this._createTermDetails(sourceTerm, expression, reading, furiganaSegments, termTags)];
const compatibilityDefinition = this._createMergedTermDefinition(
source,
rawSource,
definitions,
definitions2,
[expression],
[reading],
termDetailsList,