Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Merge branch 'MDL-62868-35' of https://github.com/snake/moodle into M…
…OODLE_35_STABLE
  • Loading branch information
David Monllao committed Jul 17, 2018
2 parents 8632026 + fb6ae10 commit 0ef5bc0
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions group/assign.php
Expand Up @@ -59,13 +59,18 @@
// Invalidate the course groups cache seeing as we've changed it.
cache_helper::invalidate_by_definition('core', 'groupdata', array(), array($courseid));

// Invalidate the user_group_groupings cache, too.
cache_helper::purge_by_definition('core', 'user_group_groupings');
} else if (isset($frm->remove) and !empty($frm->removeselect)) {
foreach ($frm->removeselect as $groupid) {
// Ask this method not to purge the cache, we'll do it ourselves afterwards.
groups_unassign_grouping($grouping->id, (int)$groupid, false);
}
// Invalidate the course groups cache seeing as we've changed it.
cache_helper::invalidate_by_definition('core', 'groupdata', array(), array($courseid));

// Invalidate the user_group_groupings cache, too.
cache_helper::purge_by_definition('core', 'user_group_groupings');
}
}

Expand Down

0 comments on commit 0ef5bc0

Please sign in to comment.