You are here

function og_entity_setter in Organic groups 7

Same name and namespace in other branches
  1. 7.2 og.module \og_entity_setter()

Entity property info setter callback to set the "entity" property for groups and memberships.

As the property is of type entity, the value will be passed as a wrapped entity.

1 string reference to 'og_entity_setter'
OgMembershipMetadataController::entityPropertyInfo in includes/og.info.inc

File

./og.module, line 321
Enable users to create and manage groups with roles and permissions.

Code

function og_entity_setter($object, $property_name, $wrapper) {
  $object->entity_type = $wrapper
    ->type();
  $object->etid = $wrapper
    ->getIdentifier();
}