You are here

function field_collection_item_get_host_entity in Field collection 7

Entity property info getter callback for the host entity property.

1 string reference to 'field_collection_item_get_host_entity'
FieldCollectionItemMetadataController::entityPropertyInfo in ./field_collection.info.inc

File

./field_collection.module, line 2013
Module implementing field collection field type.

Code

function field_collection_item_get_host_entity($item) {

  // As the property is defined as 'entity', we have to return a wrapped entity.
  return entity_metadata_wrapper($item
    ->hostEntityType(), $item
    ->hostEntity());
}