Skip to content
Snippets Groups Projects
Commit b466d937 authored by Alex Pott's avatar Alex Pott
Browse files

Issue #1990732 by joelpittet | andymartha: Fixed template_preprocess_comment()...

Issue #1990732 by joelpittet | andymartha: Fixed template_preprocess_comment() is preparing the parent's author with the wrong comment's uid.
parent 62eebd61
Branches
Tags
2 merge requests!7452Issue #1797438. HTML5 validation is preventing form submit and not fully...,!789Issue #3210310: Adjust Database API to remove deprecated Drupal 9 code in Drupal 10
......@@ -1601,7 +1601,7 @@ function template_preprocess_comment(&$variables) {
if ($comment->pid->target_id) {
// Fetch and store the parent comment information for use in templates.
$comment_parent = $comment->pid->entity;
$account_parent = comment_prepare_author($comment);
$account_parent = comment_prepare_author($comment_parent);
$variables['parent_comment'] = $comment_parent;
$variables['parent_author'] = theme('username', array('account' => $account_parent));
$variables['parent_created'] = format_date($comment_parent->created->value);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment