(route)
| 24 | }, [user]); |
| 25 | |
| 26 | const redirectUser = async (route) => { |
| 27 | const params = new URLSearchParams(window.location.search); |
| 28 | const token = params.get("token"); |
| 29 | |
| 30 | removeAuthToken(); |
| 31 | await dispatch(clearUser(true)); |
| 32 | |
| 33 | setTimeout(() => { |
| 34 | if (route === "login") { |
| 35 | navigate(`/login?inviteToken=${token}`); |
| 36 | } else { |
| 37 | navigate(`/signup?inviteToken=${token}`); |
| 38 | } |
| 39 | }, 100); |
| 40 | }; |
| 41 | |
| 42 | return ( |
| 43 | <div className="min-h-screen bg-surface-secondary px-6 py-6 sm:px-8 sm:py-8"> |
no test coverage detected