Skip to content
Browse files

MDL-21830 Prevent users from viewing names of all other site users - …

…only teachers with role assign see the full name of not enrolled users when trying to access the profile
  • Loading branch information...
1 parent e92e4b8 commit 838093ab3b1d56b8b5c500156dd6788d0cecc03b @skodak skodak committed Mar 18, 2010
Showing with 1 addition and 1 deletion.
  1. +1 −1 user/view.php
View
2 user/view.php
@@ -89,7 +89,7 @@
}
if (!has_capability('moodle/course:view', $coursecontext, $user->id, false)) {
- if (has_capability('moodle/course:view', $coursecontext)) {
+ if (has_capability('moodle/role:assign', $coursecontext)) {
$navlinks[] = array('name' => $fullname, 'link' => null, 'type' => 'misc');
$navigation = build_navigation($navlinks);
print_header("$strpersonalprofile: ", "$strpersonalprofile: ", $navigation, "", "", true, " ", navmenu($course));

0 comments on commit 838093a

Please sign in to comment.
Something went wrong with that request. Please try again.