Router: Replace landing with catch-all route

This also mitigates the issue where clicking the image-builder nav link
would redirect you to `image-builder/image-builder` if image-builder was
already opened. And `/` didn't catch that path.
This commit is contained in:
Sanne Raymaekers 2021-11-30 15:25:28 +01:00 committed by jkozol
parent 4d987eb05e
commit 6567323ef6
3 changed files with 6 additions and 7 deletions

View file

@ -117,7 +117,7 @@ const CreateImageWizard = () => {
})();
}, []);
return user ? <ImageCreator
onClose={ () => navigate('/landing') }
onClose={ () => navigate('/') }
onSubmit={ ({ values, setIsSaving }) => {
setIsSaving(() => true);
const requests = onSave(values);
@ -129,7 +129,7 @@ const CreateImageWizard = () => {
}, true));
})))
.then(() => {
navigate('/landing');
navigate('/');
dispatch(addNotification({
variant: 'success',
title: 'Your image is being created',