function og_ui_access_bundle in Organic groups 7.2
Menu access; Check permissions per-bundle editing.
Parameters
$group_type: Group entity type. E.g. 'node'.
$bundle_name: Bundle name.
Return value
True if current user is allowed to edit given bundle. False otherwise.
1 string reference to 'og_ui_access_bundle'
- og_ui_menu in og_ui/
og_ui.module - Implements hook_menu().
File
- og_ui/
og_ui.module, line 373 - Organic groups UI.
Code
function og_ui_access_bundle($group_type, $bundle_name) {
if (!user_access('administer group')) {
return FALSE;
}
$role_names = og_roles($group_type, $bundle_name);
if (!$role_names) {
return FALSE;
}
return TRUE;
}