[development] hook_user_operations permissions

Steve Yelvington steve at yelvington.com
Mon Aug 30 19:03:14 UTC 2010


I'm implementing a bulk user operation as described in sirkitree's blog 
post:
http://sirkitree.net/node/23

I don't see anything in the hook_node_operations() docs that addresses 
permissions. I'd like to provide discrete control over whether my 
operation is available, rather than having it show up in every VBO view 
that happens to return users.

Do I do that by having my implementation of hook_user_operations return 
a null array if the current user has no permissions? Or should I 
conditionally define my implementation of hook_user_operations depending 
on a user_access() call?

Or am I missing some other option?


-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.drupal.org/pipermail/development/attachments/20100830/4e79311f/attachment.html 


More information about the development mailing list