You are here

function uuid_user_features_export in UUID Features Integration 7

Implements hook_features_export().

File

includes/uuid_user.features.inc, line 35
Features hooks for the user features component.

Code

function uuid_user_features_export($data, &$export, $module_name = '') {
  $pipe = array();
  $export['dependencies']['uuid_features'] = 'uuid_features';
  $uids = entity_get_id_by_uuid('user', $data);
  foreach ($uids as $uuid => $uid) {

    // Load the existing user.
    $user = user_load($uid, TRUE);
    $export['features']['uuid_user'][$uuid] = $uuid;
    $data =& $export;
    $data['__drupal_alter_by_ref']['pipe'] =& $pipe;
    $entity_type = 'user';
    drupal_alter('uuid_entity_features_export', $entity_type, $data, $user, $module_name);
    drupal_alter('uuid_user_features_export', $data, $user, $module_name);
    unset($data['__drupal_alter_by_ref']);
  }
  return $pipe;
}