You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
What you were expecting:
I would like to notify user when getPermissions request is failing. To do it, I catch the error in checkError and I reject promise with logoutUser: false and without redirectTo as I just want to display a notification without logout or redirect the user
What happened instead:
The notification is correctly displayed but I have a JS error:
TypeError: can't access property "startsWith", redirectTo is undefined
What you were expecting:
I would like to notify user when
getPermissions
request is failing. To do it, I catch the error incheckError
and I reject promise withlogoutUser: false
and withoutredirectTo
as I just want to display a notification without logout or redirect the userWhat happened instead:
The notification is correctly displayed but I have a JS error:
This comes from
useLogoutIfAccessDenied
:react-admin/packages/ra-core/src/auth/useLogoutIfAccessDenied.ts
Lines 103 to 113 in 75a6683
Steps to reproduce:
Update
getPermissions
andcheckError
with following code:Environment
The text was updated successfully, but these errors were encountered: