summaryrefslogtreecommitdiff
path: root/src/reducers/auth.js
blob: a65b3b3e7458badcfe41c3875aa0bf339c71d26b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
import {LOG_IN_SUCCEEDED, LOG_OUT} from "../actions/auth";

export function auth(state = {}, action) {
    switch (action.type) {
        case LOG_IN_SUCCEEDED:
            return action.payload;
        case LOG_OUT:
            return {};
        default:
            return state;
    }
}