Remove unnecessary return in tab close

This commit is contained in:
Logan Ramos
2022-03-18 17:28:34 -04:00
parent eb97cfdf6d
commit 8d99738d84
2 changed files with 2 additions and 4 deletions

View File

@@ -489,7 +489,7 @@ suite('vscode API - window', () => {
// Function to acquire the active tab within the active group
const getActiveTabInActiveGroup = () => {
const activeGroup = window.tabGroups.groups.filter(group => group.isActive)[0];
return activeGroup.activeTab;
return activeGroup?.activeTab;
};
await window.showTextDocument(docA, { viewColumn: ViewColumn.One, preview: false });
@@ -514,8 +514,7 @@ suite('vscode API - window', () => {
await commands.executeCommand('workbench.action.closeActiveEditor');
await commands.executeCommand('workbench.action.closeActiveEditor');
// TODO @lramos15 fix this failing piece
//assert.ok(!getActiveTabInActiveGroup());
assert.ok(!getActiveTabInActiveGroup());
});
/*

View File

@@ -213,7 +213,6 @@ export class MainThreadEditorTabs implements MainThreadEditorTabsShape {
if (this._tabGroupModel[i].groupId === group.id) {
this._tabGroupModel.splice(i, 1);
this._groupLookup.delete(group.id);
return;
}
}
}