Coming from #1970360-99: Entities should define URI templates and standard links
Reference: https://api.drupal.org/api/drupal/core!modules!comment!comment.module/function/template_preprocess_comment/8
Problem description
- The following two code snippets are inconsistent with each other:
<?php
$permalink_uri = $comment->permalink();
$uri['options'] += array('attributes'=> array(
'class'=> 'permalink',
'rel'=> 'bookmark',
));
?><?php
$permalink_uri_parent = $comment_parent->permalink();
$permalink_uri_parent['options'] += array('attributes'=> array(
'class'=> array('permalink'),
'rel'=> 'bookmark',
));
?>
It seems as though the latter is correct and the former is simply a typo. Not sure. - The following two code snippets are also inconsistent with each other:
<?php
$variables['title'] = l($comment->subject->value, $uri['path'], $uri['options']);
?><?php
$variables['parent_title'] = l($comment_parent->subject->value, $permalink_uri_parent['path'], $permalink_uri_parent['options']);
?>
In this case it seems as though the former is correct.