diff --git a/core/lib/Drupal/Core/Entity/Field/Field.php b/core/lib/Drupal/Core/Entity/Field/Field.php index 0ff36d7..a8eea56 100644 --- a/core/lib/Drupal/Core/Entity/Field/Field.php +++ b/core/lib/Drupal/Core/Entity/Field/Field.php @@ -10,6 +10,7 @@ use Drupal\Core\Entity\Field\FieldInterface; use Drupal\Core\Session\AccountInterface; use Drupal\Core\TypedData\TypedDataInterface; +use Drupal\Core\TypedData\TypedDataManager; use Drupal\Core\TypedData\ItemList; /** @@ -39,8 +40,8 @@ class Field extends ItemList implements FieldInterface { /** * Overrides TypedData::__construct(). */ - public function __construct(array $definition, $name = NULL, TypedDataInterface $parent = NULL) { - parent::__construct($definition, $name, $parent); + public function __construct(array $definition, $name = NULL, TypedDataInterface $parent = NULL, TypedDataManager $typed_data_manager) { + parent::__construct($definition, $name, $parent, $typed_data_manager); // Always initialize one empty item as most times a value for at least one // item will be present. That way prototypes created by // \Drupal\Core\TypedData\TypedDataManager::getPropertyInstance() will diff --git a/core/lib/Drupal/Core/Entity/Field/FieldItemBase.php b/core/lib/Drupal/Core/Entity/Field/FieldItemBase.php index c51d5a1..076fde8 100644 --- a/core/lib/Drupal/Core/Entity/Field/FieldItemBase.php +++ b/core/lib/Drupal/Core/Entity/Field/FieldItemBase.php @@ -10,6 +10,7 @@ use Drupal\Core\Entity\EntityInterface; use Drupal\Core\TypedData\Plugin\DataType\Map; use Drupal\Core\TypedData\TypedDataInterface; +use Drupal\Core\TypedData\TypedDataManager; use Drupal\user; /** @@ -25,8 +26,8 @@ /** * Overrides \Drupal\Core\TypedData\TypedData::__construct(). */ - public function __construct(array $definition, $name = NULL, TypedDataInterface $parent = NULL) { - parent::__construct($definition, $name, $parent); + public function __construct(array $definition, $name = NULL, TypedDataInterface $parent = NULL, TypedDataManager $typed_data_manager) { + parent::__construct($definition, $name, $parent, $typed_data_manager); // Initialize computed properties by default, such that they get cloned // with the whole item. foreach ($this->getPropertyDefinitions() as $name => $definition) { diff --git a/core/modules/field/lib/Drupal/field/Plugin/Type/FieldType/ConfigField.php b/core/modules/field/lib/Drupal/field/Plugin/Type/FieldType/ConfigField.php index 29ce028..eb3db42 100644 --- a/core/modules/field/lib/Drupal/field/Plugin/Type/FieldType/ConfigField.php +++ b/core/modules/field/lib/Drupal/field/Plugin/Type/FieldType/ConfigField.php @@ -8,6 +8,7 @@ namespace Drupal\field\Plugin\Type\FieldType; use Drupal\Core\TypedData\TypedDataInterface; +use Drupal\Core\TypedData\TypedDataManager; use Drupal\Core\Entity\Field\Field; use Drupal\field\Field as FieldAPI; @@ -26,8 +27,8 @@ class ConfigField extends Field implements ConfigFieldInterface { /** * {@inheritdoc} */ - public function __construct(array $definition, $name = NULL, TypedDataInterface $parent = NULL) { - parent::__construct($definition, $name, $parent); + public function __construct(array $definition, $name = NULL, TypedDataInterface $parent = NULL, TypedDataManager $typed_data_manager) { + parent::__construct($definition, $name, $parent, $typed_data_manager); if (isset($definition['instance'])) { $this->instance = $definition['instance']; } diff --git a/core/modules/text/lib/Drupal/text/TextProcessed.php b/core/modules/text/lib/Drupal/text/TextProcessed.php index 9a1910f..c2638b9 100644 --- a/core/modules/text/lib/Drupal/text/TextProcessed.php +++ b/core/modules/text/lib/Drupal/text/TextProcessed.php @@ -9,6 +9,7 @@ use Drupal\Core\TypedData\TypedDataInterface; use Drupal\Core\TypedData\TypedData; +use Drupal\Core\TypedData\TypedDataManager; use Drupal\Core\TypedData\ReadOnlyException; use InvalidArgumentException; @@ -35,10 +36,10 @@ class TextProcessed extends TypedData { protected $format; /** - * Overrides TypedData::__construct(). + * {@inheritdoc} */ - public function __construct(array $definition, $name = NULL, TypedDataInterface $parent = NULL) { - parent::__construct($definition, $name, $parent); + public function __construct(array $definition, $name = NULL, TypedDataInterface $parent = NULL, TypedDataManager $typed_data_manager) { + parent::__construct($definition, $name, $parent, $typed_data_manager); if (!isset($definition['settings']['text source'])) { throw new InvalidArgumentException("The definition's 'source' key has to specify the name of the text property to be processed.");