Fix NPE on dispose when it hasn't been opened

This commit is contained in:
Daniel Imms
2019-07-25 16:49:26 -07:00
committed by GitHub
parent 26948f044d
commit 3dc52184e5
+3 -1
View File
@@ -270,7 +270,9 @@ export class Terminal extends Disposable implements ITerminal, IDisposable, IInp
this._windowsMode.dispose();
this._windowsMode = undefined;
}
this._renderService.dispose();
if (this._renderService) {
this._renderService.dispose();
}
this._customKeyEventHandler = null;
this.write = () => {};
if (this.element && this.element.parentNode) {