Skip to content

Commit

Permalink
MDL-12382 allow admins to access any course - including courses where…
Browse files Browse the repository at this point in the history
… they have guest role and course does not allow guests; merged from MOODLE_19_STABLE
  • Loading branch information
skodak committed Feb 18, 2008
1 parent 5f431c1 commit b03f721
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/moodlelib.php
Original file line number Diff line number Diff line change
Expand Up @@ -1959,7 +1959,7 @@ function require_login($courseorid=0, $autologinguest=true, $cm=null) {
if (has_capability('moodle/legacy:guest', $COURSE->context, NULL, false)) {
if (has_capability('moodle/site:doanything', $sysctx)) {
// administrators must be able to access any course - even if somebody gives them guest access
return true;
return;
}

switch ($COURSE->guest) { /// Check course policy about guest access
Expand Down

0 comments on commit b03f721

Please sign in to comment.