Skip to content

Commit

Permalink
MDL-13603 fixed course_setup() minor problem with $course in $SITE
Browse files Browse the repository at this point in the history
  • Loading branch information
skodak committed Feb 23, 2008
1 parent 2771076 commit 54a252b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/moodlelib.php
Expand Up @@ -1763,7 +1763,7 @@ function course_setup($courseorid=0) {
$COURSE = clone($courseorid);
} else {
global $course; // used here only to prevent repeated fetching from DB - may be removed later
if (!empty($course->id) and $course->id == SITEID) {
if ($courseorid == SITEID) {
$COURSE = clone($SITE);
} else if (!empty($course->id) and $course->id == $courseorid) {
$COURSE = clone($course);
Expand Down

0 comments on commit 54a252b

Please sign in to comment.