Skip to content

Commit a0b90ac

Browse files
authored
Fix microsoft#205818. Fix race condition. (microsoft#205921)
1 parent 5ca03d6 commit a0b90ac

File tree

1 file changed

+2
-1
lines changed
  • src/vs/workbench/contrib/notebook/browser/view/cellParts

1 file changed

+2
-1
lines changed

src/vs/workbench/contrib/notebook/browser/view/cellParts/codeCell.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,6 @@ export class CodeCell extends Disposable {
137137
this._register(Event.runAndSubscribe(viewCell.onDidChangeLayout, this.updateForLayout.bind(this)));
138138

139139
this._cellEditorOptions.setLineNumbers(this.viewCell.lineNumbers);
140-
this._register(this._cellEditorOptions.onDidChange(() => this.updateCodeCellOptions(templateData)));
141140
templateData.editor.updateOptions(this._cellEditorOptions.getUpdatedValue(this.viewCell.internalMetadata, this.viewCell.uri));
142141
}
143142

@@ -231,6 +230,8 @@ export class CodeCell extends Disposable {
231230

232231
focusEditorIfNeeded();
233232
}
233+
234+
this._register(this._cellEditorOptions.onDidChange(() => this.updateCodeCellOptions(this.templateData)));
234235
});
235236
}
236237

0 commit comments

Comments
 (0)