Skip to content
This repository was archived by the owner on Sep 6, 2021. It is now read-only.

Commit 684a507

Browse files
committed
Fix a unit test failure with invalid ranges when syncing folds to doc cache.
1 parent d69ade3 commit 684a507

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/extensions/default/CodeFolding/foldhelpers/foldgutter.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -175,10 +175,10 @@ define(function (require, exports, module) {
175175
range = rf(cm, CodeMirror.Pos(i));
176176
if (range && range.to.line - range.from.line >= minFoldSize) {
177177
cm._lineFolds[i] = range;
178+
i = i + range.to.line - range.from.line;
178179
} else {
179180
delete cm._lineFolds[i];
180181
}
181-
i = i + range.to.line - range.from.line;
182182
}
183183
}
184184
}

0 commit comments

Comments
 (0)