UNPKG

ih-black-lion

Version:

State handler for Arus projects

16 lines (14 loc) 474 B
import { request, invalidate, receive, initState } from '../boilerplate'; import { REQUEST_COURSES, RECEIVE_COURSES, INVALIDATE_COURSES } from '../actionTypes'; export default function(state = initState, action) { switch (action.type) { case REQUEST_COURSES: return request(state, action); case RECEIVE_COURSES: return receive(state, action); case INVALIDATE_COURSES: return invalidate(state, action); default: return state; } }