You are here

function content_type_groups_features_rebuild in Content type groups 7

Same name and namespace in other branches
  1. 7.2 content_type_groups.features.inc \content_type_groups_features_rebuild()

Implementation of hook_features_rebuild(). [component_hook]

This is called whenever a new feature is enabled, or reverted.

1 call to content_type_groups_features_rebuild()
content_type_groups_features_revert in ./content_type_groups.features.inc
Implementation of hook_features_revert(). [component_hook]

File

./content_type_groups.features.inc, line 99
Export functionality for the content type groups module.

Code

function content_type_groups_features_rebuild($module) {

  // Look for exported content type groups
  $groups = module_invoke($module, 'content_type_groups_features_default_settings');

  // Recreate groups that are in the feature
  $node_types = _content_type_groups_get_node_types();
  foreach ($groups as $machine_name => $data) {
    _content_type_groups_store_group_data($data, $node_types);
  }
}