userSaga.js 322 Bytes
Newer Older
Giang Tran committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14
import {put, takeLatest} from 'redux-saga/effects';
// @ts-ignore

import {LOGIN, UPDATE_INFOR} from '../actions/actionTypes';

function* updateUser(action) {
  try {
    yield put({type: LOGIN, data: 'asdsad'});
  } catch (error) {}
}

export function* watchUpdateUser() {
  yield takeLatest(UPDATE_INFOR, updateUser);
}