Skip to content

Commit

Permalink
Oops
Browse files Browse the repository at this point in the history
  • Loading branch information
DonJayamanne committed Oct 19, 2020
1 parent c37744d commit daded4b
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/client/datascience/notebook/kernelProvider.ts
Expand Up @@ -229,7 +229,9 @@ export class VSCodeKernelPickerProvider implements NotebookKernelProvider {
// If we already have a kernel selected, then return that.
const editor =
this.notebook.notebookEditors.find((e) => e.document === document) ||
(this.notebook.activeNotebookEditor?.document === document ? this.notebook.activeNotebookEditor : undefined);
(this.notebook.activeNotebookEditor?.document === document
? this.notebook.activeNotebookEditor
: undefined);
if (editor && editor.kernel && editor.kernel instanceof VSCodeNotebookKernelMetadata) {
return editor.kernel.selection;
}
Expand Down

0 comments on commit daded4b

Please sign in to comment.