mirror of
https://github.com/cheveguerra/whaticket-community.git
synced 2026-04-19 12:19:16 +00:00
improvement: better error messages in frontend
This commit is contained in:
@@ -32,11 +32,7 @@ const RouteWrapper = ({ component: Component, isPrivate = false, ...rest }) => {
|
||||
}
|
||||
|
||||
if (isAuth && !isPrivate) {
|
||||
return (
|
||||
<Redirect
|
||||
to={{ pathname: "/dashboard", state: { from: rest.location } }}
|
||||
/>
|
||||
);
|
||||
return <Redirect to={{ pathname: "/", state: { from: rest.location } }} />;
|
||||
}
|
||||
|
||||
return <Route {...rest} component={Component} />;
|
||||
|
||||
Reference in New Issue
Block a user