From e7b39d4d296b40a61ed2559c7e8972bd6645630d Mon Sep 17 00:00:00 2001 From: opi Date: Thu, 23 Feb 2017 17:53:17 +0100 Subject: [PATCH] =?UTF-8?q?[fix]=C2=A0Always=20redirect=20to=20portal=20wh?= =?UTF-8?q?en=20calling=20logout=20page.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- helpers.lua | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/helpers.lua b/helpers.lua index 1f23411..30046d0 100644 --- a/helpers.lua +++ b/helpers.lua @@ -808,12 +808,15 @@ function logout() -- We need this call since we are in a POST request local args = ngx.req.get_uri_args() + -- Delete user cookie if logged in (that should always be the case) if is_logged_in() then cache:delete("session_"..authUser) cache:delete(authUser.."-"..conf["ldap_identifier"]) -- Ugly trick to reload cache flash("info", t("logged_out")) - return redirect(conf.portal_url) end + + -- Redirect to portal anyway + return redirect(conf.portal_url) end