Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
First, this is a very cool module. Thank you for sharing it!
I have a situation where I want to grant specific users either view or edit access to a particular node type. When the node is published, this works great. However if the node is unpublished, both groups get an access denied error. Is this intentional or a bug?
If it's intentional, can you suggest any other modules that might help?
Comments
Comment #1
danielb CreditAttribution: danielb commentedNo that's not intentional. Just having a glance at how the node_access() function works, I think this might be a limitation of drupal. It's an assumption the drupal developers have made that the 'node access' tables should only be checked when the node is published.
I'm not sure there is anything I can suggest other than to remove
&& $node->status
from an 'if condition' in that function, which is core hacking and generally discouraged (because it will revert when upgrading drupal).Comment #2
cindyr CreditAttribution: cindyr commentedI think you're right. I gave up on having it in "unpublished" state, and I'm using this module with the Workflow module, and it appears to be working perfectly so far, haven't finished testing it yet...
Thanks for getting back to me.