X-Git-Url: https://yaffs.net/gitweb/?a=blobdiff_plain;f=web%2Fcore%2Fmodules%2Fworkspaces%2Fsrc%2FEntityTypeInfo.php;h=5495c7fa4e7c09c31db6484bc881ad7126279341;hb=1c1cb0980bfa6caf0c24cce671b6bb541dc87583;hp=3b91f84e519ef75a99c4462b7cfca51a7dd16a48;hpb=0bf8d09d2542548982e81a441b1f16e75873a04f;p=yaffs-website diff --git a/web/core/modules/workspaces/src/EntityTypeInfo.php b/web/core/modules/workspaces/src/EntityTypeInfo.php index 3b91f84e5..5495c7fa4 100644 --- a/web/core/modules/workspaces/src/EntityTypeInfo.php +++ b/web/core/modules/workspaces/src/EntityTypeInfo.php @@ -70,4 +70,18 @@ class EntityTypeInfo implements ContainerInjectionInterface { } } + /** + * Alters field plugin definitions. + * + * @param array[] $definitions + * An array of field plugin definitions. + * + * @see hook_field_info_alter() + */ + public function fieldInfoAlter(&$definitions) { + if (isset($definitions['entity_reference'])) { + $definitions['entity_reference']['constraints']['EntityReferenceSupportedNewEntities'] = []; + } + } + }