Front: If resource is not found, redirect to Error View
This commit is contained in:
committed by
Clément Le Bihan
parent
45595408fe
commit
3e84605c59
@@ -27,6 +27,7 @@ import ArtistDetailsView from './views/ArtistDetailsView';
|
||||
import { Button, Center, VStack } from 'native-base';
|
||||
import { unsetAccessToken } from './state/UserSlice';
|
||||
import TextButton from './components/TextButton';
|
||||
import ErrorView from './views/ErrorView';
|
||||
|
||||
const protectedRoutes = () =>
|
||||
({
|
||||
@@ -64,6 +65,11 @@ const protectedRoutes = () =>
|
||||
options: { title: translate('search') },
|
||||
link: '/search/:query?',
|
||||
},
|
||||
Error: {
|
||||
component: ErrorView,
|
||||
options: { title: translate('error'), headerLeft: null },
|
||||
link: undefined,
|
||||
},
|
||||
User: { component: ProfileView, options: { title: translate('user') }, link: '/user' },
|
||||
} as const);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user