Skip to content

Commit

Permalink
Remove terminal editor from service on editor close
Browse files Browse the repository at this point in the history
Fixes #127307
  • Loading branch information
Tyriar committed Jun 29, 2021
1 parent 6ad943f commit 2a8371f
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -64,9 +64,9 @@ export class TerminalEditorService extends Disposable implements ITerminalEditor
}
}));
this._register(this.onDidDisposeInstance(instance => this.detachInstance(instance)));
this._register(this._editorService.onDidCloseEditor(editor => {
if (editor instanceof TerminalEditorInput && editor.terminalInstance) {
this.detachInstance(editor.terminalInstance);
this._register(this._editorService.onDidCloseEditor(e => {
if (e.editor instanceof TerminalEditorInput && e.editor.terminalInstance) {
this.detachInstance(e.editor.terminalInstance);
}
}));
}
Expand Down

0 comments on commit 2a8371f

Please sign in to comment.