mirror of https://github.com/usememos/memos.git
fix: Update SSO login flow to encode redirect_uri (#5006)
Signed-off-by: Amazingca <autumn@amazingca.dev>
This commit is contained in:
parent
a9508b2546
commit
a3add85c95
|
|
@ -48,7 +48,7 @@ const SignIn = observer(() => {
|
||||||
}
|
}
|
||||||
const authUrl = `${oauth2Config.authUrl}?client_id=${
|
const authUrl = `${oauth2Config.authUrl}?client_id=${
|
||||||
oauth2Config.clientId
|
oauth2Config.clientId
|
||||||
}&redirect_uri=${redirectUri}&state=${stateQueryParameter}&response_type=code&scope=${encodeURIComponent(
|
}&redirect_uri=${encodeURIComponent(redirectUri)}&state=${stateQueryParameter}&response_type=code&scope=${encodeURIComponent(
|
||||||
oauth2Config.scopes.join(" "),
|
oauth2Config.scopes.join(" "),
|
||||||
)}`;
|
)}`;
|
||||||
window.location.href = authUrl;
|
window.location.href = authUrl;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue