react_persist_login icon indicating copy to clipboard operation
react_persist_login copied to clipboard

Running in strict mode, in dev - accessing Admin (and users) instantly navigates to login

Open stuehler opened this issue 2 years ago • 0 comments

I may have introduced a bug, but when I run this using Strict mode in development, React mounts and then instantly unmounts the Users component. This cancels the axios request that was initiated by the use effect.

Canceling that request triggers the catch block on lines 22-25, which navigates the user to the login screen.

So, any time I navigate to the Admin/Users route, I'm instantly navigated to the Login screen.

stuehler avatar Jul 21 '23 11:07 stuehler