import { HYDRATE } from 'next-redux-wrapper';

import * as actionTypes from '../constants/actionTypes';
import initialState from "./initialState";

const adminReducer = (state = initialState.admin, action) => 
{
	switch (action.type) 
	{
		case actionTypes.ADMIN: 
		{
			return {
				...state, 
				...action.data, 
			};
		}

		default: {
			return state;
		}
	}
};

export default adminReducer;