removed unnecessary calls to get_site()

This commit is contained in:
gustav_delius 2004-08-29 14:15:40 +00:00
parent afd97e8449
commit 222ac91bc9
26 changed files with 219 additions and 415 deletions

View file

@ -1252,11 +1252,6 @@ function print_course($course, $width="100%") {
$enrol = new enrolment_plugin;
}
if (! $site = get_site()) {
error("Could not find a site!");
}
print_simple_box_start("center", "$width", $THEME->cellcontent, 5, "coursebox");
$linkcss = $course->visible ? "" : " class=\"dimmed\" ";
@ -1274,7 +1269,7 @@ function print_course($course, $width="100%") {
$teacher->role = $course->teacher;
}
$fullname = fullname($teacher, isteacher($course->id)); // is the USER a teacher of that course
echo "$teacher->role: <a href=\"$CFG->wwwroot/user/view.php?id=$teacher->id&course=$site->id\">$fullname</a><br />";
echo "$teacher->role: <a href=\"$CFG->wwwroot/user/view.php?id=$teacher->id&course=".SITEID."\">$fullname</a><br />";
}
}
echo "</font></p>";