提交 cb53ff5e 编写于 作者: D Daniel Imms

Add null check to TerminalPanel.focus

Fixes #22368
上级 8e5179d1
......@@ -137,7 +137,10 @@ export class TerminalPanel extends Panel {
}
public focus(): void {
this._terminalService.getActiveInstance().focus(true);
const activeInstance = this._terminalService.getActiveInstance();
if (activeInstance) {
activeInstance.focus(true);
}
}
private _attachEventListeners(): void {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册