From 79c11b6b9eb1b82722892d85a03eba3d3a2d6122 Mon Sep 17 00:00:00 2001 From: xjm <xjm@65776.no-reply.drupal.org> Date: Mon, 6 Jul 2015 12:19:15 +0100 Subject: [PATCH] Issue #2492585 by pguillard, yarik.lutsiuk, andypost, Mile23: Deprecate comment_view() & comment_view_multiple() --- core/modules/comment/comment.module | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/core/modules/comment/comment.module b/core/modules/comment/comment.module index 8bcac2cedfd9..b256da67965e 100644 --- a/core/modules/comment/comment.module +++ b/core/modules/comment/comment.module @@ -257,6 +257,9 @@ function comment_node_view_alter(array &$build, EntityInterface $node, EntityVie * * @return array * An array as expected by drupal_render(). + * + * @deprecated in Drupal 8.x and will be removed before Drupal 9.0. + * Use \Drupal::entityManager()->getViewBuilder('comment')->view(). */ function comment_view(CommentInterface $comment, $view_mode = 'full', $langcode = NULL) { return entity_view($comment, $view_mode, $langcode); @@ -277,6 +280,9 @@ function comment_view(CommentInterface $comment, $view_mode = 'full', $langcode * @return array * An array in the format expected by drupal_render(). * + * @deprecated in Drupal 8.x and will be removed before Drupal 9.0. + * Use \Drupal::entityManager()->getViewBuilder('comment')->viewMultiple(). + * * @see drupal_render() */ function comment_view_multiple($comments, $view_mode = 'full', $langcode = NULL) { -- GitLab