Skip to content

Commit f44ae52

Browse files
committed
remove more code to fix tests
1 parent e463ea1 commit f44ae52

File tree

1 file changed

+1
-19
lines changed

1 file changed

+1
-19
lines changed

packages/compass-connections/src/stores/connections-store-redux.ts

Lines changed: 1 addition & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -969,28 +969,10 @@ const reducer: Reducer<State, Action> = (state = INITIAL_STATE, action) => {
969969
const newConnection = createDefaultConnectionState();
970970
newConnection.isBeingCreated = true;
971971

972-
let newConnectionsState = state.connections;
973-
974-
// Only relevant for single connections mode: if we're currently editing
975-
// "new connection", clean it up from state before creating state for a new
976-
// one
977-
if (
978-
state.editingConnectionInfoId &&
979-
state.connections.byId[state.editingConnectionInfoId].isBeingCreated
980-
) {
981-
newConnectionsState = {
982-
...newConnectionsState,
983-
byId: {
984-
...newConnectionsState.byId,
985-
},
986-
};
987-
delete newConnectionsState.byId[state.editingConnectionInfoId];
988-
}
989-
990972
return {
991973
...state,
992974
connections: mergeConnectionStateById(
993-
newConnectionsState,
975+
state.connections,
994976
newConnection.info.id,
995977
newConnection
996978
),

0 commit comments

Comments
 (0)