public function Group::addSubgroup in Group 7
Add a subgroup to a group.
Parameters
Group $group: The subgroup to attach to the group.
File
- classes/
group.inc, line 218 - Defines the Entity API class for groups.
Class
- Group
- Main class for groups.
Code
public function addSubgroup(Group $group) {
drupal_set_message(t('Deprecation notice!<br />Group::addSubgroup() will soon be removed. Please use Group::addEntity() instead.'), 'warning');
$this
->addEntity($group->gid, 'group', $group->type);
}