We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent bba7c9e commit e7f5cd4Copy full SHA for e7f5cd4
src/client/jupyter/common/cells.ts
@@ -24,10 +24,12 @@ export class CellHelper {
24
});
25
}
26
27
- if (cells.length > 1 && index === document.lineCount - 1) {
28
- const previousCell = cells[cells.length - 1];
29
- previousCell.range = new Range(previousCell.range.start, line.range.end);
30
- }
+ }
+
+ if (cells.length >= 1) {
+ const line = document.lineAt(document.lineCount - 1);
31
+ const previousCell = cells[cells.length - 1];
32
+ previousCell.range = new Range(previousCell.range.start, line.range.end);
33
34
return cells;
35
0 commit comments