mirror of
https://github.com/moodle/moodle.git
synced 2025-01-19 06:18:28 +01:00
Merge branch 'w02_MDL-37483_m25_redirect' of git://github.com/skodak/moodle
This commit is contained in:
commit
f38ac3510a
@ -3082,7 +3082,12 @@ function require_login($courseorid = NULL, $autologinguest = true, $cm = NULL, $
|
||||
if ($preventredirect) {
|
||||
throw new require_login_exception('Activity is hidden');
|
||||
}
|
||||
redirect($CFG->wwwroot, get_string('activityiscurrentlyhidden'));
|
||||
if ($course->id != SITEID) {
|
||||
$url = new moodle_url('/course/view.php', array('id'=>$course->id));
|
||||
} else {
|
||||
$url = new moodle_url('/');
|
||||
}
|
||||
redirect($url, get_string('activityiscurrentlyhidden'));
|
||||
}
|
||||
|
||||
// Finally access granted, update lastaccess times
|
||||
|
Loading…
x
Reference in New Issue
Block a user