Permissions problem when trying to have author only access to tribune nodes

Agogo - August 1, 2009 - 14:03
Project:Tribune
Version:6.x-2.0-beta2
Component:Code
Category:feature request
Priority:normal
Assigned:Unassigned
Status:needs review
Description

Since Tribune overrides other permission modules I had the problem not to be able to choose the permission that only administrators and the author could read tribunes. I fixed the problem by changing this line in tribune.module:

return user_access('read tribunes');

to:

return user_access('read tribunes') and ($user->uid == $node->uid);

Just FYI for others who has the same problem and maby for the module author for a small change?

Anyhow, as others has stated; the module should be built otherwise as it ignores other permission modules settings.

#1

Agogo - August 10, 2009 - 12:40

Or with only access for author and admins:
return user_access('read tribunes') and (($user->uid == $node->uid) or (in_array('administrator', $user->roles)));

#2

kubajs - August 17, 2009 - 14:03
Title:Permissions problem when trying to have author only access to tribune nodes» Zebra support
Version:6.x-2.0-beta2» 6.x-1.10

sorry i pasted unintentional comment here - can somebody delete this?

#3

Flying Drupalist - September 12, 2009 - 23:12
Title:Zebra support» Permissions problem when trying to have author only access to tribune nodes
Version:6.x-1.10» 6.x-2.0-beta2
 
 

Drupal is a registered trademark of Dries Buytaert.