From a50cc165d01037ebef512eb623d18d41f162b8e3 Mon Sep 17 00:00:00 2001 From: Michael M Slusarz Date: Thu, 11 Nov 2010 12:06:31 -0700 Subject: [PATCH] Don't show logout reasons more than once if user was successfully deauthenticated --- horde/login.php | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/horde/login.php b/horde/login.php index 913afc622..086bfb720 100644 --- a/horde/login.php +++ b/horde/login.php @@ -109,6 +109,19 @@ if ($vars->url) { if (!($logout_reason = $auth->getError())) {; $logout_reason = $vars->logout_reason; } + +switch ($logout_reason) { +case Horde_Auth::REASON_SESSION: +case Horde_Core_Auth_Application::REASON_SESSIONIP: +case Horde_Core_Auth_Application::REASON_BROWSER: +case Horde_Auth::REASON_LOGOUT: + /* Don't show these logout reasons more than once. */ + if (!$is_auth) { + $logout_reason = null; + } + break; +} + if ($logout_reason) { if ($is_auth) { try { -- 2.11.0