We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b175ab3 commit 4a6cbddCopy full SHA for 4a6cbdd
src/ViewModels/Launcher.cs
@@ -204,12 +204,7 @@ public void CloseTab(LauncherPage page)
204
var activeIdx = Pages.IndexOf(_activePage);
205
if (removeIdx == activeIdx)
206
{
207
- ActivePage = Pages[removeIdx == Pages.Count - 1 ? removeIdx - 1 : removeIdx + 1];
208
- CloseRepositoryInTab(page);
209
- Pages.RemoveAt(removeIdx);
210
- }
211
- else if (removeIdx + 1 == activeIdx)
212
- {
+ ActivePage = Pages[removeIdx > 0 ? removeIdx - 1 : removeIdx + 1];
213
CloseRepositoryInTab(page);
214
Pages.RemoveAt(removeIdx);
215
}
0 commit comments