mirror of
https://github.com/supermemoryai/supermemory.git
synced 2026-09-11 22:51:05 +00:00
handle expired plugin connect sessions
This commit is contained in:
parent
40519683c8
commit
22cf75912d
1 changed files with 7 additions and 0 deletions
|
|
@ -248,6 +248,13 @@ function AuthConnectContent() {
|
|||
Array.isArray(organizations) &&
|
||||
organizations.length === 0
|
||||
|
||||
useEffect(() => {
|
||||
if (requestError || isPending || isRestoring || session) return
|
||||
router.replace(
|
||||
`/login?redirect=${encodeURIComponent(window.location.href)}`,
|
||||
)
|
||||
}, [isPending, isRestoring, requestError, router, session])
|
||||
|
||||
useEffect(() => {
|
||||
if (requestError) return
|
||||
if (isPending || isRestoring) return
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue