function privatemsg_roles_perm in Privatemsg 6.2
Implements hook_perm().
File
- privatemsg_roles/
privatemsg_roles.module, line 11 - Allows to send messages to all members of a role.
Code
function privatemsg_roles_perm() {
$perms = array(
'view roles recipients',
'write privatemsg to all roles',
);
foreach (user_roles(TRUE) as $role) {
$perms[] = 'write privatemsg to role ' . $role;
}
return $perms;
}