function role_export_role_name_exists in Role Export 7
Check if the machine name of the new role already exists.
1 string reference to 'role_export_role_name_exists'
- role_export_form_alter in ./
role_export.module - Implements hook_form_alter().
File
- ./
role_export.module, line 77 - Role Export's primary module file.
Code
function role_export_role_name_exists($value) {
$roles = role_export_roles();
foreach ($roles as $role) {
if ($role->machine_name == $value) {
return $value;
}
}
}