*/
export function rootReducer(state: RootState, action: RootAction, log?: (msg: string) => void): RootState {
case ActionType.RootAgentsChanged:
return { ...state, agents: action.agents };
case ActionType.RootActiveSessionsChanged:
return { ...state, activeSessions: action.activeSessions };
case ActionType.RootTerminalsChanged:
return { ...state, terminals: action.terminals };
case ActionType.RootConfigChanged:
if (!state.config) {
return state;