style: lint
This commit is contained in:
parent
5ad9d2bc0f
commit
d85834c08d
13
src/App.tsx
13
src/App.tsx
@ -35,7 +35,9 @@ const App = () => {
|
|||||||
|
|
||||||
const handleRootRedirect = () => {
|
const handleRootRedirect = () => {
|
||||||
if (authState.loggedIn) return appPrivateRoutes.homePage
|
if (authState.loggedIn) return appPrivateRoutes.homePage
|
||||||
const callbackPathEncoded = btoa(window.location.href.split(`${window.location.origin}/#`)[1])
|
const callbackPathEncoded = btoa(
|
||||||
|
window.location.href.split(`${window.location.origin}/#`)[1]
|
||||||
|
)
|
||||||
return `${appPublicRoutes.login}?callbackPath=${callbackPathEncoded}`
|
return `${appPublicRoutes.login}?callbackPath=${callbackPathEncoded}`
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -72,14 +74,7 @@ const App = () => {
|
|||||||
}
|
}
|
||||||
})}
|
})}
|
||||||
|
|
||||||
<Route
|
<Route path="*" element={<Navigate to={handleRootRedirect()} />} />
|
||||||
path="*"
|
|
||||||
element={
|
|
||||||
<Navigate
|
|
||||||
to={handleRootRedirect()}
|
|
||||||
/>
|
|
||||||
}
|
|
||||||
/>
|
|
||||||
</Route>
|
</Route>
|
||||||
</Routes>
|
</Routes>
|
||||||
)
|
)
|
||||||
|
Loading…
Reference in New Issue
Block a user