Show avatar when logged in and support logging out
This commit is contained in:
@@ -23,7 +23,8 @@ const initialState =
|
||||
restartIceInProgress : false,
|
||||
picture : null,
|
||||
selectedWebcam : null,
|
||||
selectedAudioDevice : null
|
||||
selectedAudioDevice : null,
|
||||
loggedIn : false
|
||||
};
|
||||
|
||||
const me = (state = initialState, action) =>
|
||||
@@ -50,6 +51,12 @@ const me = (state = initialState, action) =>
|
||||
};
|
||||
}
|
||||
|
||||
case 'LOGGED_IN':
|
||||
return { ...state, loggedIn: true };
|
||||
|
||||
case 'USER_LOGOUT':
|
||||
return { ...state, loggedIn: false };
|
||||
|
||||
case 'CHANGE_WEBCAM':
|
||||
{
|
||||
return { ...state, selectedWebcam: action.payload.deviceId };
|
||||
|
||||
Reference in New Issue
Block a user