mirror of
https://github.com/moodle/moodle.git
synced 2025-08-04 16:36:37 +02:00
Changed ($course) to ($this->course) in if condition to allow course to be checked
This commit is contained in:
parent
3c4a6298bc
commit
a1931e61d5
1 changed files with 2 additions and 1 deletions
|
@ -23,7 +23,7 @@ class CourseBlock_admin extends MoodleBlock {
|
||||||
$this->content->icons = array();
|
$this->content->icons = array();
|
||||||
$this->content->footer = '';
|
$this->content->footer = '';
|
||||||
|
|
||||||
if (empty($course)) {
|
if (empty($this->course)) {
|
||||||
$this->content = '';
|
$this->content = '';
|
||||||
} else if ($this->course->category == 0) {
|
} else if ($this->course->category == 0) {
|
||||||
$this->load_content_for_site();
|
$this->load_content_for_site();
|
||||||
|
@ -68,6 +68,7 @@ class CourseBlock_admin extends MoodleBlock {
|
||||||
|
|
||||||
function load_content_for_course() {
|
function load_content_for_course() {
|
||||||
global $CFG, $USER;
|
global $CFG, $USER;
|
||||||
|
|
||||||
require_once($CFG->dirroot.'/mod/forum/lib.php');
|
require_once($CFG->dirroot.'/mod/forum/lib.php');
|
||||||
|
|
||||||
if (isguest()) {
|
if (isguest()) {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue