Skip to content

Commit ad1d8bb

Browse files
committed
oops
1 parent 2c4176d commit ad1d8bb

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

src/vs/workbench/contrib/notebook/browser/notebook.contribution.ts

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -808,10 +808,9 @@ class NotebookEditorManager implements IWorkbenchContribution {
808808
// --- Start Positron ---
809809
// Make sure that we dont try and open the same editor twice if we're using positron
810810
// notebooks.
811-
for (const positronInstance of this._positronNotebookService.listInstances(model.resource)) {
812-
if (positronInstance.connectedToEditor) {
813-
continue;
814-
}
811+
const positronInstances = this._positronNotebookService.listInstances(model.resource);
812+
if (positronInstances.some(instance => instance.connectedToEditor)) {
813+
continue;
815814
}
816815
// --- End Positron ---
817816
result.push({

0 commit comments

Comments
 (0)