chore: temporarily loosen CORS, add OAuth state info for backend bouncing

This commit is contained in:
41666 2021-03-13 15:49:36 -05:00
parent ed82a67594
commit 6edfe7455f
8 changed files with 72 additions and 9 deletions

View file

@ -11,9 +11,10 @@ const Login = () => {
React.useEffect(() => {
const url = new URL(window.location.href);
const callbackHost = `${url.protocol}://${url.host}`;
const redirectServerID = url.searchParams.get('r');
if (!redirectServerID) {
window.location.href = `${apiUrl}/login-bounce`;
window.location.href = `${apiUrl}/login-bounce?cbh=${callbackHost}`;
return;
}