]> git.mjollnir.org Git - moodle.git/commit
accesslib: has_capability() now loads sub-course accessdata for $ACCESS
authormartinlanghoff <martinlanghoff>
Wed, 19 Sep 2007 07:26:02 +0000 (07:26 +0000)
committermartinlanghoff <martinlanghoff>
Wed, 19 Sep 2007 07:26:02 +0000 (07:26 +0000)
commit420bfab1564672cbe0158472a58b995b49d087ba
tree650b5494ab7bcc29149e838f44e2a3f763ea617f
parent21e2dcd946f9e89a2c410ca1c0bdd91d567efa40
accesslib: has_capability() now loads sub-course accessdata for $ACCESS

When querying capabilities of non-logged-in users, has_capability()
will now load accessdata for the subcontexts as needed.

Without this patch, below-the-course RAs and rdefs were ignored when
checking caps for a user different from $USER. I don't think it is
ever done in current moodle code, so the problem wasn't visible.

In any case - it's fixed ;-)
lib/accesslib.php