]> git.mjollnir.org Git - moodle.git/commitdiff
Bug fixes:
authorvyshane <vyshane>
Tue, 22 Aug 2006 05:35:52 +0000 (05:35 +0000)
committervyshane <vyshane>
Tue, 22 Aug 2006 05:35:52 +0000 (05:35 +0000)
1) Replaced isteacher call in fullname ($course undefined)
2) Initialised $options array

admin/roles/assign.php

index 250def848df0928af8b59d5959d1c6679ef399c0..9fb40a83c58b31ff981982cb83fa415f722d7f9a 100755 (executable)
@@ -64,7 +64,7 @@
     
     $participants = get_string("participants");
     $user = get_record('user', 'id', $userid);
-    $fullname = fullname($user, isteacher($course->id));
+    $fullname = fullname($user, has_capability('moodle/site:viewfullnames', $context));
 
     // we got a few tabs there
     if ($context->aggregatelevel == CONTEXT_USERID) {
         
     // this needs to check capability too
     $role = get_records('role');
+    $options = array();
     foreach ($role as $rolex) {
         if (user_can_assign($context, $rolex->id)) {
             $options[$rolex->id] = $rolex->name;