mirror of
https://github.com/steveiliop56/tinyauth.git
synced 2026-02-25 10:22:00 +00:00
fix: final review comments
This commit is contained in:
@@ -109,10 +109,6 @@ export const AuthorizePage = () => {
|
||||
},
|
||||
});
|
||||
|
||||
if (!isLoggedIn) {
|
||||
return <Navigate to={`/login?${compiledOIDCParams}`} replace />;
|
||||
}
|
||||
|
||||
if (missingParams.length > 0) {
|
||||
return (
|
||||
<Navigate
|
||||
@@ -122,6 +118,10 @@ export const AuthorizePage = () => {
|
||||
);
|
||||
}
|
||||
|
||||
if (!isLoggedIn) {
|
||||
return <Navigate to={`/login?${compiledOIDCParams}`} replace />;
|
||||
}
|
||||
|
||||
if (getClientInfo.isLoading) {
|
||||
return (
|
||||
<Card className="min-w-xs sm:min-w-sm">
|
||||
|
||||
@@ -90,7 +90,9 @@ export const LoginPage = () => {
|
||||
mutationKey: ["login"],
|
||||
onSuccess: (data) => {
|
||||
if (data.data.totpPending) {
|
||||
window.location.replace(`/totp?${compiledOIDCParams}`);
|
||||
window.location.replace(
|
||||
`/totp?redirect_uri=${encodeURIComponent(props.redirect_uri)}`,
|
||||
);
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user