diff options
author | toasted-nutbread <toasted-nutbread@users.noreply.github.com> | 2021-09-05 21:07:23 -0400 |
---|---|---|
committer | toasted-nutbread <toasted-nutbread@users.noreply.github.com> | 2021-09-11 16:05:39 -0400 |
commit | 39a704e2afb3e0103824d9e202de91a43853c374 (patch) | |
tree | c3bc6bda74177ea8ebd826835934b291cbca4696 /ext/js | |
parent | 048089ec698fb8237fa0cd5df668f4cfc0b83cab (diff) |
Fix incorrect index being used for headword removal (#1933)
Diffstat (limited to 'ext/js')
-rw-r--r-- | ext/js/language/translator.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/js/language/translator.js b/ext/js/language/translator.js index c35d2203..2df39299 100644 --- a/ext/js/language/translator.js +++ b/ext/js/language/translator.js @@ -535,7 +535,7 @@ class Translator { const indexRemap = new Map(); let oldIndex = 0; for (let i = 0, ii = headwords.length; i < ii; ++i) { - if (removeHeadwordIndices.has(i)) { + if (removeHeadwordIndices.has(oldIndex)) { headwords.splice(i, 1); --i; --ii; |