Issue #3338844 by Rassoni, dpi, smustgrave, longwave: Remove mention of removed function entity_view()

merge-requests/3559/merge
catch 2023-04-14 16:02:10 +01:00
parent 1021a1f137
commit 2b6fade769
2 changed files with 3 additions and 3 deletions

View File

@ -16,7 +16,7 @@ use Symfony\Component\DependencyInjection\ContainerInterface;
* @FieldFormatter( * @FieldFormatter(
* id = "entity_reference_entity_view", * id = "entity_reference_entity_view",
* label = @Translation("Rendered entity"), * label = @Translation("Rendered entity"),
* description = @Translation("Display the referenced entities rendered by entity_view()."), * description = @Translation("Render the referenced entity."),
* field_types = { * field_types = {
* "entity_reference" * "entity_reference"
* } * }

View File

@ -525,8 +525,8 @@ function comment_preview(CommentInterface $comment, FormStateInterface $form_sta
// parent entity output rendering the comment form and the comment form // parent entity output rendering the comment form and the comment form
// rendering the parent entity. To prevent this infinite loop we temporarily // rendering the parent entity. To prevent this infinite loop we temporarily
// set the value of the comment field on a clone of the entity to hidden // set the value of the comment field on a clone of the entity to hidden
// before calling entity_view(). That way when the output of the commented // before calling the entity view builder. That way when the output of
// entity is rendered, it excludes the comment field output. // the commented entity is rendered, it excludes the comment field output.
$field_name = $comment->getFieldName(); $field_name = $comment->getFieldName();
$entity = clone $entity; $entity = clone $entity;
$entity->$field_name->status = CommentItemInterface::HIDDEN; $entity->$field_name->status = CommentItemInterface::HIDDEN;