fix(auth): bind handleUnauthenticated to correct context (#4120)

This commit is contained in:
Sofien-Sellami 2024-05-14 17:56:58 +01:00 committed by GitHub
parent 2de102c73c
commit 8fa339f296
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -149,7 +149,7 @@ const createRoutes = ({
exact
path={route.path}
element={
<PrivateRoute handleUnauthenticated={userAuthenticationService.handleUnauthenticated}>
<PrivateRoute handleUnauthenticated={() => userAuthenticationService.handleUnauthenticated()}>
<RouteWithErrorBoundary route={route} />
</PrivateRoute>
}