Skip to content

Commit 601efc3

Browse files
authored
Merge pull request #5253 from akphi/patch-1
bug: properly render the terminal when open() is called again
2 parents af4208d + 62656b8 commit 601efc3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/browser/CoreBrowserTerminal.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -400,7 +400,7 @@ export class CoreBrowserTerminal extends CoreTerminal implements ITerminal {
400400
}
401401

402402
// If the terminal is already opened
403-
if (this.element?.ownerDocument.defaultView && this._coreBrowserService) {
403+
if (this.element?.ownerDocument.defaultView && this._coreBrowserService && this.element?.isConnected) {
404404
// Adjust the window if needed
405405
if (this.element.ownerDocument.defaultView !== this._coreBrowserService.window) {
406406
this._coreBrowserService.window = this.element.ownerDocument.defaultView;

0 commit comments

Comments
 (0)