Details
-
Type:
Bug
-
Status:
Open
-
Priority:
Major
-
Resolution: Unresolved
-
Affects Version/s: 1.9.5, 1.9.6
-
Fix Version/s: None
-
Component/s: Roles / Access
-
Labels:None
-
Affected Branches:MOODLE_19_STABLE
Description
As posted on development forum (http://moodle.org/mod/forum/discuss.php?d=134417) , the function role_unassign only check for group membership if the contextlevel is the course.
I am posting a patch that do this job for every contextlevel < COURSE , and finds all the child contexts, iterates over them and in the course ones checks the capability and do the group membership removal.
Hope you like.
This second patch (ra_groups_remove_v2.diff) should be applied instead of the first one, cause it tests if context_childs is really an array, avoiding php warnings