Skip to content

Commit 5569f84

Browse files
committed
Call ChatTab.close when closing tabs
1 parent d6b59e3 commit 5569f84

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

Core/Sources/SuggestionWidget/FeatureReducers/ChatPanel.swift

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,7 @@ public struct ChatPanel {
8080
case chatTab(id: String, action: ChatTabItem.Action)
8181
}
8282

83+
@Dependency(\.chatTabPool) var chatTabPool
8384
@Dependency(\.suggestionWidgetControllerDependency) var suggestionWidgetControllerDependency
8485
@Dependency(\.xcodeInspector) var xcodeInspector
8586
@Dependency(\.activatePreviousActiveXcode) var activatePreviouslyActiveXcode
@@ -197,6 +198,7 @@ public struct ChatPanel {
197198
return max(nextIndex, 0)
198199
}()
199200
state.chatTabGroup.tabInfo.removeAll { $0.id == id }
201+
chatTabPool.getTab(of: id)?.close()
200202
if state.chatTabGroup.tabInfo.isEmpty {
201203
state.isPanelDisplayed = false
202204
}

0 commit comments

Comments
 (0)