Remove unnecessary var declaration in WindowService (#133)

This commit is contained in:
Evan Simkowitz 2024-07-22 16:43:18 -07:00 committed by GitHub
parent 198ec60e69
commit 21e5e94db4
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -64,9 +64,8 @@ func (svc *WindowService) CloseTab(ctx context.Context, uiContext wstore.UIConte
if err != nil {
return nil, fmt.Errorf("error getting workspace: %w", err)
}
var newActiveTabId string
if len(ws.TabIds) > 0 {
newActiveTabId = ws.TabIds[0]
newActiveTabId := ws.TabIds[0]
wstore.SetActiveTab(ctx, uiContext.WindowId, newActiveTabId)
} else {
eventbus.SendEventToElectron(eventbus.WSEventType{