client/src/reducers/sessionsReducer.js
changeset 132 906a6c7c7943
parent 129 d48946d164c6
child 168 ea92f4fe783d
equal deleted inserted replaced
131:adad5563603c 132:906a6c7c7943
    73       const sessionId = action.session.get('_id');
    73       const sessionId = action.session.get('_id');
    74       const index = state.findIndex((session) => session.get('_id') === sessionId);
    74       const index = state.findIndex((session) => session.get('_id') === sessionId);
    75       const session = state.get(index);
    75       const session = state.get(index);
    76       return state.set(index, session.merge({action: ActionEnum.NONE}));
    76       return state.set(index, session.merge({action: ActionEnum.NONE}));
    77     }
    77     }
       
    78     case types.AUTH_LOGOUT: {
       
    79       return Immutable.List(); // empty session list on logout
       
    80     }
    78     default:
    81     default:
    79       return state;
    82       return state;
    80   }
    83   }
    81 };
    84 };