commit 70905cc478486d64ad20db4bd90a32b907e2de24 Author: gnuget Date: Tue Apr 30 18:42:54 2013 -0500 http://drupal.org/node/1898434#comment-7362208 diff --git a/core/modules/options/options.api.php b/core/modules/options/options.api.php index 43c4d21..0c48fec 100644 --- a/core/modules/options/options.api.php +++ b/core/modules/options/options.api.php @@ -79,20 +79,17 @@ function hook_options_list($field, $instance, $entity) { * '_none' option might have been added, depending on the field properties. * * @param array $context - * An array with these values: - * - * @param \Drupal\field\Plugin\Core\Entity\Field $field - * The field definition. - * @param Drupal\field\Plugin\Core\Entity\FieldInstance $instance - * The instance definition. It is recommended to only use instance level - * properties to filter out values from a list defined by field level - * properties. - * @param \Drupal\Core\Entity\EntityInterface $entity - * The entity object the field is attached to. + * Context array on the performed operation with the following keys: + * - field: The field definition (\Drupal\field\Plugin\Core\Entity\Field). + * - instance: The instance definition. It is recommended to only use + * instance level properties to filter out values from a list defined + * by field level properties (Drupal\field\Plugin\Core\Entity\FieldInstance). + * - entity: The entity object the field is attached to + * (\Drupal\Core\Entity\EntityInterface). * * @see hook_options_list() */ -function hook_options_list_alter(&$options, $context) { +function hook_options_list_alter(array &$options, array $context) { // Check if is the field where want be changed the label of the _none option if ($context['field']->id == 'field_option') { // Change the label of the _none option