Skip to content

Commit

Permalink
Properly fix #133687 (#136085)
Browse files Browse the repository at this point in the history
  • Loading branch information
jeanp413 authored and Tyriar committed Nov 1, 2021
1 parent 8575b85 commit 2683773
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions src/vs/workbench/contrib/terminal/browser/terminalService.ts
Original file line number Diff line number Diff line change
Expand Up @@ -435,7 +435,7 @@ export class TerminalService implements ITerminalService {
}
} else {
// add split terminals to this group
await this.createTerminal({ config: { attachPersistentProcess: terminalLayout.terminal! }, location: { parentTerminal: terminalInstance } });
terminalInstance = await this.createTerminal({ config: { attachPersistentProcess: terminalLayout.terminal! }, location: { parentTerminal: terminalInstance } });
}
}
const activeInstance = this.instances.find(t => {
Expand Down Expand Up @@ -1371,10 +1371,6 @@ export class TerminalService implements ITerminalService {
}

private _getSplitParent(location?: ITerminalLocationOptions): ITerminalInstance | undefined {
if (this._connectionState === TerminalConnectionState.Connecting && this.activeInstance) {
const group = this._terminalGroupService.getGroupForInstance(this.activeInstance);
return group?.terminalInstances[group.terminalInstances.length - 1];
}
if (location && typeof location === 'object' && 'parentTerminal' in location) {
return location.parentTerminal;
} else if (location && typeof location === 'object' && 'splitActiveTerminal' in location) {
Expand Down

0 comments on commit 2683773

Please sign in to comment.