Closed (fixed)
Project:
OG Private Content
Version:
6.x-1.1
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Reporter:
Created:
28 Mar 2011 at 21:05 UTC
Updated:
2 May 2011 at 17:55 UTC
When an unauthorized user tries to access a private content by typing its URL, the call to drupal_access_denied() in og_orivate_content_nodeapi() generates an infinite recursion on my Drupal install.
I think the right way to prevent access to private content would be to use the node access system (by implementing hook_node_access_records() and hook_node_grants()).
Patrick
Comments
Comment #1
cghobbs commentedpfournier your right that would be a much better approach than what I've cobbled together so far and I do hope to do that soon. I had a bit of trouble getting that to actually work when I first tried it but I stumbled across this module that I think will be helpful to borrow from: http://drupal.org/project/private The use case is very similar accept that it doesn't work for OG.
Comment #2
branana commentedRemoved extraneous call to drupal_access_denied()
Comment #3
branana commentedComment #4
johannez commentedNow when you try to access a private content node as an unauthorized user you will guided to the login page.
Comment #5
johannez commented