2018-01-24 11:24:49 -08:00
|
|
|
import * as actions from 'constants/channel_action_types';
|
2018-01-18 09:33:26 -08:00
|
|
|
|
|
|
|
const initialState = {
|
|
|
|
loggedInChannel: {
|
|
|
|
name : null,
|
|
|
|
shortId: null,
|
|
|
|
longId : null,
|
|
|
|
},
|
|
|
|
};
|
|
|
|
|
|
|
|
export default function (state = initialState, action) {
|
|
|
|
switch (action.type) {
|
|
|
|
case actions.CHANNEL_UPDATE:
|
|
|
|
return Object.assign({}, state, {
|
2018-02-06 12:11:44 -08:00
|
|
|
loggedInChannel: action.data,
|
2018-01-18 09:33:26 -08:00
|
|
|
});
|
|
|
|
default:
|
|
|
|
return state;
|
|
|
|
}
|
|
|
|
}
|