You are here

function social_tagging_inline_entity_form_entity_form_alter in Open Social 8.9

Same name and namespace in other branches
  1. 10.3.x modules/social_features/social_tagging/social_tagging.module \social_tagging_inline_entity_form_entity_form_alter()
  2. 10.0.x modules/social_features/social_tagging/social_tagging.module \social_tagging_inline_entity_form_entity_form_alter()
  3. 10.1.x modules/social_features/social_tagging/social_tagging.module \social_tagging_inline_entity_form_entity_form_alter()
  4. 10.2.x modules/social_features/social_tagging/social_tagging.module \social_tagging_inline_entity_form_entity_form_alter()

Implements hook_inline_entity_form_entity_form_alter().

This hook allows to have a compatibility with "Inline Entity Form" module.

File

modules/social_features/social_tagging/social_tagging.module, line 107
Contains social_tagging.module.

Code

function social_tagging_inline_entity_form_entity_form_alter(&$entity_form, &$form_state) {

  // Act if the form has the tagging field.
  if (isset($entity_form['social_tagging'])) {

    // "Inline entity form" module has an entity object in the "form" variable.
    social_tagging_social_tagging_field_form_alter($entity_form, $form_state, $entity_form['#entity']);
  }
}