Closed (fixed)
Project:
Module Grants
Version:
6.x-3.6
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Reporter:
Created:
5 Nov 2010 at 19:48 UTC
Updated:
25 Jul 2011 at 01:42 UTC
Hi,
I'm trying to understand if there is a reason that the setting of $or_modules is hard-coded to TRUE in module_grants_node_revision_access() rather than using the config setting like in module_grants_node_access. We have a module doing access checking, which returns FALSE from hook_user_node_access(), but since the revisioning module says yes the user is given access. If I change node_revision_access to use the config value, it works as expected and our module is able to block access as required.
}
// See if other modules have anything to say about this revision_op, i.e.
// whether they implement hook_user_node_access($revision_op, $node).
$or_modules = TRUE; // variable_get('module_grants_OR_modules', FALSE);
$hook = 'user_node_access';
foreach (module_implements($hook) as $module) {
$result = module_invoke($module, $hook, $revision_op, $node);
Thanks for any clarification!
Comments
Comment #1
rdeboerI can't think of a reason to disagree with you -- looks like I forgot to uncomment the rest of that line!
Checked in.