Skip to content
Permalink
Browse files

MDL-46619 Forum: only output last poster's name if user can view it.

  • Loading branch information...
Michael de Raadt Damyon Wiese
Michael de Raadt authored and Damyon Wiese committed Sep 2, 2014
1 parent c256614 commit 532c25d5bd6d0f2ad14720fcee0da8c879c4d0f2
Showing with 4 additions and 2 deletions.
  1. +4 −2 mod/forum/lib.php
@@ -3887,8 +3887,10 @@ function forum_print_discussion_header(&$post, $forum, $group=-1, $datestring=""
$usermodified = new stdClass();
$usermodified->id = $post->usermodified;
$usermodified = username_load_fields_from_object($usermodified, $post, 'um');
echo '<a href="'.$CFG->wwwroot.'/user/view.php?id='.$post->usermodified.'&amp;course='.$forum->course.'">'.
fullname($usermodified).'</a><br />';
if ($canviewparticipants) {
echo '<a href="'.$CFG->wwwroot.'/user/view.php?id='.$post->usermodified.'&amp;course='.$forum->course.'">'.
fullname($usermodified).'</a><br />';
}
echo '<a href="'.$CFG->wwwroot.'/mod/forum/discuss.php?d='.$post->discussion.$parenturl.'">'.
userdate($usedate, $datestring).'</a>';
echo "</td>\n";

0 comments on commit 532c25d

Please sign in to comment.
You can’t perform that action at this time.