From 4d50aac4eee478c09ccc22e7c40b1b93b8ac93ec Mon Sep 17 00:00:00 2001 From: Eric Bailey Date: Thu, 21 Mar 2024 14:11:23 -0500 Subject: Release fixes (#3318) * Fix error overflow * await setSavedFeeds before setting birth date * await birth date first instead of feeds --------- Co-authored-by: Samuel Newman --- src/components/forms/FormError.tsx | 2 +- src/screens/Signup/state.ts | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/components/forms/FormError.tsx b/src/components/forms/FormError.tsx index 9e72df879..8ab6e3f35 100644 --- a/src/components/forms/FormError.tsx +++ b/src/components/forms/FormError.tsx @@ -20,7 +20,7 @@ export function FormError({error}: {error?: string}) { a.gap_sm, ]}> - + {error} diff --git a/src/screens/Signup/state.ts b/src/screens/Signup/state.ts index f185e2d44..86a144368 100644 --- a/src/screens/Signup/state.ts +++ b/src/screens/Signup/state.ts @@ -207,7 +207,7 @@ export function useSubmitSignup({ }) { const {_} = useLingui() const {createAccount} = useSessionApi() - const {mutate: setBirthDate} = usePreferencesSetBirthDateMutation() + const {mutateAsync: setBirthDate} = usePreferencesSetBirthDateMutation() const {mutate: setSavedFeeds} = useSetSaveFeedsMutation() const onboardingDispatch = useOnboardingDispatch() @@ -264,7 +264,7 @@ export function useSubmitSignup({ inviteCode: state.inviteCode.trim(), verificationCode: verificationCode, }) - setBirthDate({birthDate: state.dateOfBirth}) + await setBirthDate({birthDate: state.dateOfBirth}) if (IS_PROD_SERVICE(state.serviceUrl)) { setSavedFeeds(DEFAULT_PROD_FEEDS) } -- cgit 1.4.1