import { types } from "../actions/actionTypes";

const initialState = {
  subCategoryData: {},
  top20ShowData: {},
};

export const mainReducer = (state = initialState, action) => {
  switch (action.type) {
    case types.GET_SUB_CATEGORY:
      return {
        ...state,
        subCategoryData: action.payload,
      };

    case types.GET_TOP_20_SHOW:
      return {
        ...state,
        top20ShowData: action.payload,
      };

    default:
      return state;
  }
};
