mirror of
https://github.com/lukevella/rallly.git
synced 2025-06-08 05:31:51 +02:00
Revert "♻️ Update how guest session is handled"
This reverts commit b5c20533d2
.
This commit is contained in:
parent
b5c20533d2
commit
41f85279bb
2 changed files with 27 additions and 22 deletions
|
@ -71,6 +71,11 @@ export const UserProvider = (props: { children?: React.ReactNode }) => {
|
||||||
token: legacyToken,
|
token: legacyToken,
|
||||||
redirect: false,
|
redirect: false,
|
||||||
});
|
});
|
||||||
|
} else {
|
||||||
|
// End: Legacy token migration
|
||||||
|
signIn("guest", {
|
||||||
|
redirect: false,
|
||||||
|
});
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
|
|
|
@ -62,7 +62,6 @@ export default withAuth(
|
||||||
value: legacyToken.value,
|
value: legacyToken.value,
|
||||||
httpOnly: false,
|
httpOnly: false,
|
||||||
});
|
});
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
// Create new guest user
|
// Create new guest user
|
||||||
const newUser = `user-${randomid()}`;
|
const newUser = `user-${randomid()}`;
|
||||||
|
@ -87,6 +86,7 @@ export default withAuth(
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
return res;
|
return res;
|
||||||
},
|
},
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue