pleroma/app/soapbox/reducers/patron.js
2020-07-04 14:14:36 -05:00

13 lines
360 B
JavaScript

import { PATRON_INSTANCE_FETCH_SUCCESS } from '../actions/patron';
import { Map as ImmutableMap, fromJS } from 'immutable';
const initialState = ImmutableMap();
export default function patron(state = initialState, action) {
switch(action.type) {
case PATRON_INSTANCE_FETCH_SUCCESS:
return fromJS(action.instance);
default:
return state;
}
};