From 708502c37dbe82e85764a97d9b43ab8ed0ed6a6b Mon Sep 17 00:00:00 2001 From: James McQuillan Date: Tue, 1 Oct 2019 03:00:02 -0400 Subject: [PATCH] MSFTMPP-782: Fix for logged-in guests --- classes/loginflow/authcode.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/classes/loginflow/authcode.php b/classes/loginflow/authcode.php index a446cfd..7f21fc4 100644 --- a/classes/loginflow/authcode.php +++ b/classes/loginflow/authcode.php @@ -106,7 +106,7 @@ public function handleredirect() { // Response from OP. $this->handleauthresponse($requestparams); } else { - if (isloggedin() && empty($justauth) && empty($promptaconsent)) { + if (isloggedin() && !isguestuser() && empty($justauth) && empty($promptaconsent)) { if (isset($SESSION->wantsurl) and (strpos($SESSION->wantsurl, $CFG->wwwroot) === 0)) { $urltogo = $SESSION->wantsurl; unset($SESSION->wantsurl);