Posted by michaelj on August 6, 2009 at 10:07am
| Project: | Node Relativity |
| Version: | 6.x-1.x-dev |
| Component: | Code |
| Category: | bug report |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | closed (fixed) |
Issue Summary
Hi, in function relativity_access_listnodes($op, $node, $user_access) $node is not object so variable shouldn't be use in node_access('update', $node) because it cause 'Access denied'. Fast improvement: $node=node_load($node);
Comments
#1
Extending the title to describe the use case when this happens. Attached patch implements the solution suggested by jancor.
#2
attachment..
#3
and here is a more elaborated patch that simplifies the code a bit.
#4
I ran into the same problem, and found the same cause. The first patch is the solution I used as well, but it is quick and dirty. The second patch, which uses %node, is the more correct drupal way to do it, IMO, and should be preferred.
#5
Commited. http://drupal.org/cvs?commit=417806
#6
Automatically closed -- issue fixed for 2 weeks with no activity.