mirror of
https://github.com/moodle/moodle.git
synced 2025-08-05 00:46:50 +02:00
Fix for the display of hidden forums to students - bug 1209
This commit is contained in:
parent
07c270c127
commit
9c8b8eeeb5
1 changed files with 7 additions and 1 deletions
|
@ -68,7 +68,13 @@
|
|||
|
||||
foreach ($forums as $forum) {
|
||||
if (!isset($forum->visible)) {
|
||||
$forum->visible = true;
|
||||
$forum->visible = instance_is_visible("forum", $forum);
|
||||
if (!$forum->visible and !isteacher($course->id)) {
|
||||
if (isset($forum->keyreference)) {
|
||||
unset($learningforums[$forum->keyreference]);
|
||||
}
|
||||
continue;
|
||||
}
|
||||
}
|
||||
switch ($forum->type) {
|
||||
case "news":
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue