Sign up ×
Drupal Answers is a question and answer site for Drupal developers and administrators. It's 100% free, no registration required.

I want to change permissions for nodes by hook_node_access_records() and hook_node_grants(), but I want to allow access to a node only if the workflow access module has granted access to it.

something like:


if (workflow_access_allowed() && myModule_allowed()) {
  allow()
}
else {
  disallow()
}

How do I check wheather workflow_access has already granted access to node? (My module priority in grants array in hook_node_access_records() is higher than the workflow access module.

share|improve this question

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.