diff --git a/core/modules/comment/comment.services.yml b/core/modules/comment/comment.services.yml new file mode 100644 index 0000000..3599592 --- /dev/null +++ b/core/modules/comment/comment.services.yml @@ -0,0 +1,5 @@ +services: + comment.breadcrumb: + class: Drupal\comment\CommentBreadcrumbBuilder + tags: + - { name: breadcrumb_builder, priority: 100 } diff --git a/core/modules/comment/lib/Drupal/comment/CommentBreadcrumbBuilder.php b/core/modules/comment/lib/Drupal/comment/CommentBreadcrumbBuilder.php new file mode 100644 index 0000000..fcaf24a --- /dev/null +++ b/core/modules/comment/lib/Drupal/comment/CommentBreadcrumbBuilder.php @@ -0,0 +1,30 @@ +uri(); + $breadcrumb[] = l(t('Home'), NULL); + $breadcrumb[] = l($node->label(), $uri['path']); + return $breadcrumb; + } + } + +} diff --git a/core/modules/comment/lib/Drupal/comment/Controller/CommentController.php b/core/modules/comment/lib/Drupal/comment/Controller/CommentController.php index 2f1cc8f..b847611 100644 --- a/core/modules/comment/lib/Drupal/comment/Controller/CommentController.php +++ b/core/modules/comment/lib/Drupal/comment/Controller/CommentController.php @@ -181,8 +181,6 @@ public function commentPermalink(Request $request, CommentInterface $comment) { */ public function getReply(NodeInterface $node, $pid, Request $request) { $uri = $node->uri(); - // Set the breadcrumb trail. - drupal_set_breadcrumb(array(l(t('Home'), NULL), l($node->label(), $uri['path']))); $op = $request->request->get('op'); $build = array();