update deps, added logout clear store
This commit is contained in:
@@ -9,9 +9,14 @@ import {
|
||||
setFormEmail,
|
||||
setFormPassword,
|
||||
setFormPasswordConfirmation,
|
||||
setFormOldPassword
|
||||
setFormOldPassword,
|
||||
setClearAuthState
|
||||
} from "../actions/auth/reducer.actions";
|
||||
import { setSelfUser } from "../actions/user/reducer.actions";
|
||||
import {
|
||||
setSelfUser,
|
||||
setClearUserState
|
||||
} from "../actions/user/reducer.actions";
|
||||
import { setClearWorktypeState } from "../actions/worktype/reducer.actions";
|
||||
import {
|
||||
registerUser,
|
||||
verifyEmail,
|
||||
@@ -62,6 +67,9 @@ function* loginUserCall(postBody) {
|
||||
}
|
||||
|
||||
function* logoutUserCall() {
|
||||
yield effects.put(setClearAuthState());
|
||||
yield effects.put(setClearUserState());
|
||||
yield effects.put(setClearWorktypeState());
|
||||
yield effects.call(logoutUser);
|
||||
}
|
||||
|
||||
|
||||
@@ -11,7 +11,15 @@ import {
|
||||
} from "../actions/user/reducer.actions";
|
||||
import { getSelfUserRequest } from "../actions/user/saga.actions";
|
||||
import { CLIENT_OR_PROVIDER_STEP } from "../constants/user.constants";
|
||||
import { getSelfUser, createUserInfo, updateUserInfo, createClient, updateClient, createProvider, updateProvider } from "../api/user.api";
|
||||
import {
|
||||
getSelfUser,
|
||||
createUserInfo,
|
||||
updateUserInfo,
|
||||
createClient,
|
||||
updateClient,
|
||||
createProvider,
|
||||
updateProvider
|
||||
} from "../api/user.api";
|
||||
|
||||
function* getSelfUserCall() {
|
||||
yield effects.put(isSendingUserRequest(true));
|
||||
|
||||
Reference in New Issue
Block a user