Skip to content

Commit a6815ab

Browse files
authored
Skip cells that don't have any code in them (microsoft#6644)
1 parent 2d1a066 commit a6815ab

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/client/datascience/editor-integration/cellhashprovider.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ export class CellHashProvider implements ICellHashProvider, IInteractiveWindowLi
111111
const lines = splitMultilineString(cell.data.source);
112112
const stripped = lines.filter(l => !cellMatcher.isCode(l));
113113

114-
if (stripped.length > 0 && stripped.find(s => s.length > 0)) {
114+
if (stripped.length > 0 && stripped.find(s => s.trim().length > 0)) {
115115
// When the user adds new code, we know the execution count is increasing
116116
this.executionCount += 1;
117117

0 commit comments

Comments
 (0)