chore: fix earn points redirect; restore account feedback (#1400)

* redirect to country picker

* fix button restoring state

* fix earn points flow and account recovery feedback

* redirect to the country picker

* fix test

* clean up
This commit is contained in:
Justin Hernandez
2025-11-12 06:07:13 -08:00
committed by GitHub
parent 642d532dd9
commit 2753de3509
2 changed files with 3 additions and 3 deletions

View File

@@ -49,7 +49,7 @@ export const useEarnPointsFlow = ({
onButtonPress: () => {
// Use setTimeout to ensure modal dismisses before navigating
setTimeout(() => {
navigation.navigate('DocumentOnboarding');
navigation.navigate('CountryPicker');
}, 100);
},
onModalDismiss: () => {

View File

@@ -135,7 +135,7 @@ describe('useEarnPointsFlow', () => {
});
});
it('should navigate to DocumentOnboarding when identity verification modal button is pressed', async () => {
it('should navigate to CountryPicker when identity verification modal button is pressed', async () => {
mockHasUserAnIdentityDocumentRegistered.mockResolvedValue(false);
const { result } = renderHook(() =>
@@ -162,7 +162,7 @@ describe('useEarnPointsFlow', () => {
jest.advanceTimersByTime(100);
});
expect(mockNavigate).toHaveBeenCalledWith('DocumentOnboarding');
expect(mockNavigate).toHaveBeenCalledWith('CountryPicker');
});
it('should clear referrer when identity verification modal is dismissed with referrer', async () => {