12 Jan
2010
12 Jan
'10
2:55 p.m.
user_roles isn't loaded yet, but the global $user is populated and the roles are stored inside of that as an array, so you can do it as hook_boot, but you need to manually check the roles. Jamie Holly http://www.intoxination.net http://www.hollyit.net On 1/12/2010 7:56 AM, LluĂs wrote:
I need to check roles for a permission at hook_boot; but I recive a "Fatal error: Call to undefined function user_roles()". Is it possible that user_roles() is not defined at hook_boot? or am I missing something else?
thanks.