UserSignUp: skip user fetch

Talking to Tom, we think this can be removed, since the regular startup could would eventually call `new` to get a token.
This commit is contained in:
infinite-persistence 2021-12-14 14:43:04 +08:00
parent eccb542610
commit 569ff3077f
No known key found for this signature in database
GPG key ID: B9C3252EDC3D0AA0
2 changed files with 0 additions and 8 deletions

View file

@ -4,7 +4,6 @@ import { selectGetSyncIsPending, selectSyncHash, selectPrefsReady } from 'redux/
import { doClaimRewardType } from 'redux/actions/rewards'; import { doClaimRewardType } from 'redux/actions/rewards';
import { doSetClientSetting } from 'redux/actions/settings'; import { doSetClientSetting } from 'redux/actions/settings';
import { selectClaimedRewards, makeSelectIsRewardClaimPending } from 'redux/selectors/rewards'; import { selectClaimedRewards, makeSelectIsRewardClaimPending } from 'redux/selectors/rewards';
import { doUserFetch } from 'redux/actions/user';
import { import {
selectUserIsPending, selectUserIsPending,
selectYoutubeChannels, selectYoutubeChannels,
@ -45,7 +44,6 @@ const select = (state) => ({
}); });
const perform = (dispatch) => ({ const perform = (dispatch) => ({
fetchUser: () => dispatch(doUserFetch()),
claimConfirmEmailReward: () => claimConfirmEmailReward: () =>
dispatch( dispatch(
doClaimRewardType(REWARD_TYPES.TYPE_CONFIRM_EMAIL, { doClaimRewardType(REWARD_TYPES.TYPE_CONFIRM_EMAIL, {

View file

@ -34,7 +34,6 @@ type Props = {
claimingReward: boolean, claimingReward: boolean,
claimConfirmEmailReward: () => void, claimConfirmEmailReward: () => void,
claimNewUserReward: () => void, claimNewUserReward: () => void,
fetchUser: () => void,
claimedRewards: Array<Reward>, claimedRewards: Array<Reward>,
youtubeChannels: Array<any>, youtubeChannels: Array<any>,
syncEnabled: boolean, syncEnabled: boolean,
@ -60,7 +59,6 @@ function UserSignUp(props: Props) {
claimConfirmEmailReward, claimConfirmEmailReward,
claimNewUserReward, claimNewUserReward,
balance, balance,
fetchUser,
youtubeChannels, youtubeChannels,
syncEnabled, syncEnabled,
syncingWallet, syncingWallet,
@ -132,10 +130,6 @@ function UserSignUp(props: Props) {
setClientSetting(setting, value, true); setClientSetting(setting, value, true);
} }
React.useEffect(() => {
fetchUser();
}, [fetchUser]);
React.useEffect(() => { React.useEffect(() => {
if (previousHasVerifiedEmail === false && hasVerifiedEmail && prefsReady) { if (previousHasVerifiedEmail === false && hasVerifiedEmail && prefsReady) {
setSettingAndSync(SETTINGS.FIRST_RUN_STARTED, true); setSettingAndSync(SETTINGS.FIRST_RUN_STARTED, true);