Skip to content

Commit

Permalink
Merge branch 'MDL-39947_23' of https://github.com/aolley/moodle into …
Browse files Browse the repository at this point in the history
…MOODLE_23_STABLE
  • Loading branch information
danpoltawski committed Jun 10, 2013
2 parents 61603bb + 8d148dd commit bb059c3
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion mod/forum/lib.php
Expand Up @@ -6717,7 +6717,11 @@ function forum_tp_count_forum_unread_posts($cm, $course) {
$modinfo->groups = groups_get_user_groups($course->id, $USER->id);
}

$mygroups = $modinfo->groups[$cm->groupingid];
if (array_key_exists($cm->groupingid, $modinfo->groups)) {
$mygroups = $modinfo->groups[$cm->groupingid];
} else {
$mygroups = false; // Will be set below
}

// add all groups posts
if (empty($mygroups)) {
Expand Down

0 comments on commit bb059c3

Please sign in to comment.