Skip to content

Commit 6545c4c

Browse files
authored
Remove redundant variable (microsoft#185170)
1 parent f8a02c3 commit 6545c4c

File tree

1 file changed

+0
-3
lines changed

1 file changed

+0
-3
lines changed

src/vs/base/browser/ui/list/listWidget.ts

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,6 @@ class Trait<T> implements ISpliceable<boolean>, IDisposable {
130130
const diff = elements.length - deleteCount;
131131
const end = start + deleteCount;
132132
const sortedIndexes: number[] = [];
133-
let firstSortedIndex: number | undefined = undefined;
134133
let i = 0;
135134

136135
while (i < this.sortedIndexes.length && this.sortedIndexes[i] < start) {
@@ -140,13 +139,11 @@ class Trait<T> implements ISpliceable<boolean>, IDisposable {
140139
for (let j = 0; j < elements.length; j++) {
141140
if (elements[j]) {
142141
sortedIndexes.push(j + start);
143-
firstSortedIndex = firstSortedIndex ?? sortedIndexes[sortedIndexes.length - 1];
144142
}
145143
}
146144

147145
while (i < this.sortedIndexes.length && this.sortedIndexes[i] >= end) {
148146
sortedIndexes.push(this.sortedIndexes[i++] + diff);
149-
firstSortedIndex = firstSortedIndex ?? sortedIndexes[sortedIndexes.length - 1];
150147
}
151148

152149
const length = this.length + diff;

0 commit comments

Comments
 (0)