in classes/output/core_renderer.php [70:85]
public function user_link() {
global $USER, $OUTPUT;
if (!empty($USER->id)) {
$profilepagelink = new moodle_url('/user/profile.php', ['id' => $USER->id]);
$profilepic = $OUTPUT->user_picture($USER, ['size' => 26, 'link' => false]);
$userfullname = fullname($USER);
$piclink = html_writer::link($profilepagelink, $profilepic, ['target' => '_blank', 'class' => 'user_details']);
$userprofile = html_writer::link($profilepagelink, $userfullname, ['target' => '_blank']);
return $piclink . $userprofile;
} else {
return "";
}
}