public function GroupRoleController::delete in Group 7
Delete a group role.
Overrides EntityAPIControllerExportable::delete
See also
File
- classes/
group_role.controller.inc, line 17 - Defines the Entity API CRUD class for group roles.
Class
- GroupRoleController
- Controller for group role entities.
Code
public function delete($ids, DatabaseTransaction $transaction = NULL) {
if (!empty($ids)) {
foreach (group_roles($ids) as $group_role) {
// Invalidate the parent group type's GroupRole cache.
$group_role
->invalidateTypeCache();
// Flag parent type as ENTITY_CUSTOM.
$group_role
->flagTypeCustom();
// Add Internationalization module support.
if (module_exists('i18n_string')) {
i18n_string_object_remove('group_role', $group_role);
}
}
}
parent::delete($ids, $transaction);
}