From 8b635c5d44dc8841850a5bba21ded3bd443d22b9 Mon Sep 17 00:00:00 2001 From: LLLL Colonq Date: Mon, 18 Nov 2024 06:11:58 -0500 Subject: Check redirect --- src/Auth.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src/Auth.js') diff --git a/src/Auth.js b/src/Auth.js index 9d5060c..246052c 100644 --- a/src/Auth.js +++ b/src/Auth.js @@ -49,6 +49,8 @@ export const _clearSessionCookie = () => { document.cookie = "authelia_session=; expires=Thu, 01 Jan 1970 00:00:00 GMT; SameSite=None; Secure"; }; -export const getRedirect = (x) => { - return x.redirect; +export const _getRedirect = (Just) => (Nothing) => (x) => () => { + const r = x["data"]["redirect"]; + if (r) return Just(r); + return Nothing; }; -- cgit v1.2.3