You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

13 lines
316 B

  1. import { TRENDS_FETCH_SUCCESS } from '../actions/trends';
  2. import { fromJS } from 'immutable';
  3. const initialState = null;
  4. export default function trendsReducer(state = initialState, action) {
  5. switch(action.type) {
  6. case TRENDS_FETCH_SUCCESS:
  7. return fromJS(action.trends);
  8. default:
  9. return state;
  10. }
  11. };