Skip to content

Commit

Permalink
feat(sso): remove ts ignore from saga register
Browse files Browse the repository at this point in the history
  • Loading branch information
TheLeoB committed Dec 11, 2021
1 parent 29356e2 commit 6398023
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,6 @@ export default ({ api, coreSagas, networks }) => {
yield takeLatest(actions.initializeLogin.type, authSagas.initializeLogin)
yield takeLatest(actions.triggerWalletMagicLink.type, authSagas.triggerWalletMagicLink)
yield takeLatest(actions.getUserGeoLocation.type, authSagas.getUserGeoLocation)
// @ts-ignore
yield takeLatest(actions.loginRoutine.type, authSagas.loginRoutineSaga)
yield takeLatest(actions.exchangeLogin.type, authSagas.exchangeLogin)
yield takeLatest(actions.exchangeResetPassword.type, authSagas.exchangeResetPassword)
yield takeLatest(actions.continueLoginProcess, authSagas.continueLoginProcess)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ import {
pollForSessionFromGuid
} from './sagas.utils'
import * as S from './selectors'
import { actions as A } from './slice'
import {
AccountUnificationFlows,
LoginErrorType,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ import {
ExchangeResetPasswordFailureType,
ExchangeResetPasswordSuccessType,
LoginFailureType,
LoginRoutinePayloadType,
LoginSuccessType,
MetadataRestoreType,
PlatformTypes,
Expand Down Expand Up @@ -137,7 +138,7 @@ const authSlice = createSlice({
loginLoading: (state) => {
state.login = Remote.Loading
},
loginRoutine: () => {},
loginRoutine: (state, action: PayloadAction<LoginRoutinePayloadType>) => {},
loginSuccess: (state, action: PayloadAction<LoginSuccessType>) => {
state.login = Remote.Success(action.payload)
},
Expand Down
12 changes: 6 additions & 6 deletions packages/blockchain-wallet-v4-frontend/src/data/auth/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -59,12 +59,12 @@ export type RecoverFormType = {
step: RecoverSteps
}

export type LoginPayloadType = {
code: string
guid: string
mobileLogin: boolean
password: string
sharedKey: string
export type LoginRoutinePayloadType = {
country?: string
email?: string
firstLogin?: boolean
recovery?: boolean
state?: string
}

export type ExchangeLoginType = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,9 @@ const UpgradeSuccess = (props: Props) => {
nature='primary'
fullwidth
height='48px'
onClick={() => props.authActions.loginRoutine()}
// commented out for now, undeeded until upgrade flows
// ReturnType on login routine saga
// onClick={() => props.authActions.loginRoutine()}
data-e2e='iUnderstandWalletRedirect'
style={{ marginTop: '16px' }}
>
Expand Down

0 comments on commit 6398023

Please sign in to comment.