]> git.mjollnir.org Git - moodle.git/commit
accesslib: has_cap_fad() respect local-context-wins permissions rule
authormartinlanghoff <martinlanghoff>
Wed, 19 Sep 2007 07:52:06 +0000 (07:52 +0000)
committermartinlanghoff <martinlanghoff>
Wed, 19 Sep 2007 07:52:06 +0000 (07:52 +0000)
commitc7a8ec8cf0ba78ad8e1d63a7b1db5cc06cd6c83a
tree30e3c794eb8dc82d9f3721866b5dcc4f893646f5
parent5b9e50caf022ee91a1c2fd657ea344d471040843
accesslib: has_cap_fad() respect local-context-wins permissions rule

The initial implementation of has_cap_fad() just added the permission
values regardless of the locality of the context. This patch adds
support (read: fixes bug) for the "local context wins" rule.

Additionally, it removes a related bug where we were exiting early
if we found a CAP_PROHIBIT, ignoring the $doanything flag.
lib/accesslib.php