MDL-9170 https redirect doesn't happen on login page - fixed problem when guest button disabled
This commit is contained in:
+1
-1
@@ -1636,7 +1636,7 @@ function require_login($courseorid=0, $autologinguest=true, $cm=null) {
|
||||
if (!empty($_SERVER['HTTP_REFERER'])) {
|
||||
$SESSION->fromurl = $_SERVER['HTTP_REFERER'];
|
||||
}
|
||||
if ($autologinguest and !empty($CFG->autologinguests) and ($COURSE->id == SITEID or $COURSE->guest) ) {
|
||||
if ($autologinguest and !empty($CFG->guestloginbutton) and !empty($CFG->autologinguests) and ($COURSE->id == SITEID or $COURSE->guest) ) {
|
||||
$loginguest = '?loginguest=true';
|
||||
} else {
|
||||
$loginguest = '';
|
||||
|
||||
Reference in New Issue
Block a user