docker fixes
This commit is contained in:
@@ -36,16 +36,12 @@ export default function ConsentPage() {
|
||||
|
||||
const handleDecision = async (allow: boolean) => {
|
||||
setIsSubmitting(true);
|
||||
if (allow) {
|
||||
const result = await Approve(sessionToken, allow);
|
||||
if (result) {
|
||||
window.location.href = result;
|
||||
} else {
|
||||
setError(t("invalidSession"));
|
||||
setIsSubmitting(false);
|
||||
}
|
||||
const result = await Approve(sessionToken, allow);
|
||||
if (result) {
|
||||
window.location.href = result;
|
||||
} else {
|
||||
window.location.href = session?.redirect_uri || "/";
|
||||
setError(t("invalidSession"));
|
||||
setIsSubmitting(false);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
@@ -35,7 +35,11 @@ export default function LoginPage() {
|
||||
|
||||
useEffect(() => {
|
||||
if (redirectTo) {
|
||||
router.push(redirectTo);
|
||||
if (redirectTo.startsWith("http")) {
|
||||
window.location.href = redirectTo;
|
||||
} else {
|
||||
router.push(redirectTo);
|
||||
}
|
||||
}
|
||||
}, [redirectTo, router]);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user