ace2_inner: Fix for..in iteration

See commit c38c34bef4.
pull/5153/head
Richard Hansen 2021-08-15 02:48:26 -04:00
parent 2d50a8aa95
commit f06307cb4c
1 changed files with 5 additions and 7 deletions

View File

@ -2263,13 +2263,11 @@ function Ace2Inner(editorInfo, cssManagers) {
detectChangesAroundLine(0, 1); detectChangesAroundLine(0, 1);
detectChangesAroundLine(N - 1, 1); detectChangesAroundLine(N - 1, 1);
for (const k in observedChanges.cleanNodesNearChanges) { for (const k of Object.keys(observedChanges.cleanNodesNearChanges)) {
if (observedChanges.cleanNodesNearChanges[k]) { const key = k.substring(1);
const key = k.substring(1); if (rep.lines.containsKey(key)) {
if (rep.lines.containsKey(key)) { const line = rep.lines.indexOfKey(key);
const line = rep.lines.indexOfKey(key); detectChangesAroundLine(line, 2);
detectChangesAroundLine(line, 2);
}
} }
} }
} }