summaryrefslogtreecommitdiff
path: root/ext/js/data/anki-note-data-creator.js
diff options
context:
space:
mode:
authortoasted-nutbread <toasted-nutbread@users.noreply.github.com>2021-06-05 22:27:58 -0400
committerGitHub <noreply@github.com>2021-06-05 22:27:58 -0400
commitd87515ec125189ceeae251d37013b511c7bf8baf (patch)
tree2c52130b8ced8efbd371cc2e9f5e5f0678242d76 /ext/js/data/anki-note-data-creator.js
parent057283245e2a2ce55f89cacb42067b8c93dd28cd (diff)
Translator id updates (#1730)
* Allow unsequenced definitions to be added to multiple groups * Update translator data to store multiple IDs * Update Anki note data * Update test data * Update docs
Diffstat (limited to 'ext/js/data/anki-note-data-creator.js')
-rw-r--r--ext/js/data/anki-note-data-creator.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/ext/js/data/anki-note-data-creator.js b/ext/js/data/anki-note-data-creator.js
index 4cf62788..c76369c3 100644
--- a/ext/js/data/anki-note-data-creator.js
+++ b/ext/js/data/anki-note-data-creator.js
@@ -274,7 +274,7 @@ class AnkiNoteDataCreator {
case 'merge': type = 'termMerged'; break;
}
- const {id, inflections, score, dictionaryIndex, dictionaryPriority, sourceTermExactMatchCount} = dictionaryEntry;
+ const {ids, inflections, score, dictionaryIndex, dictionaryPriority, sourceTermExactMatchCount} = dictionaryEntry;
const {
screenshotFileName=null,
@@ -301,7 +301,7 @@ class AnkiNoteDataCreator {
return {
type,
- id: (type === 'term' ? id : void 0),
+ id: (type === 'term' ? ids[0] : void 0),
source: (primarySource !== null ? primarySource.transformedText : null),
rawSource: (primarySource !== null ? primarySource.originalText : null),
sourceTerm: (type !== 'termMerged' ? (primarySource !== null ? primarySource.deinflectedText : null) : void 0),