mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-11-22 18:00:18 +01:00
Fixed issue where the "lock screen" shows up briefly between the "create password" screen and the success screen (#14111)
Co-authored-by: Alex Donesky <adonesky@gmail.com>
This commit is contained in:
parent
2118b4825d
commit
31f0b245c3
@ -21,8 +21,6 @@ import {
|
||||
} from '../../helpers/constants/routes';
|
||||
import {
|
||||
getCompletedOnboarding,
|
||||
getIsInitialized,
|
||||
getIsUnlocked,
|
||||
getSeedPhraseBackedUp,
|
||||
} from '../../ducks/metamask/metamask';
|
||||
import {
|
||||
@ -54,8 +52,6 @@ export default function OnboardingFlow() {
|
||||
const currentLocation = useLocation();
|
||||
const history = useHistory();
|
||||
const t = useI18nContext();
|
||||
const isInitialized = useSelector(getIsInitialized);
|
||||
const isUnlocked = useSelector(getIsUnlocked);
|
||||
const completedOnboarding = useSelector(getCompletedOnboarding);
|
||||
const seedPhraseBackedUp = useSelector(getSeedPhraseBackedUp);
|
||||
const nextRoute = useSelector(getFirstTimeFlowTypeRoute);
|
||||
@ -63,19 +59,8 @@ export default function OnboardingFlow() {
|
||||
useEffect(() => {
|
||||
if (completedOnboarding && seedPhraseBackedUp) {
|
||||
history.push(DEFAULT_ROUTE);
|
||||
return;
|
||||
}
|
||||
|
||||
if (isInitialized && !isUnlocked) {
|
||||
history.push(ONBOARDING_UNLOCK_ROUTE);
|
||||
}
|
||||
}, [
|
||||
history,
|
||||
completedOnboarding,
|
||||
isInitialized,
|
||||
isUnlocked,
|
||||
seedPhraseBackedUp,
|
||||
]);
|
||||
}, [history, completedOnboarding, seedPhraseBackedUp]);
|
||||
|
||||
const handleCreateNewAccount = async (password) => {
|
||||
const newSecretRecoveryPhrase = await dispatch(
|
||||
|
Loading…
Reference in New Issue
Block a user