]> git.mjollnir.org Git - moodle.git/commitdiff
Merged MDL-13637 from 1.9
authormoodler <moodler>
Mon, 25 Feb 2008 03:50:18 +0000 (03:50 +0000)
committermoodler <moodler>
Mon, 25 Feb 2008 03:50:18 +0000 (03:50 +0000)
tag/locallib.php

index 33dbb55cce161c919b6841b23f2b10a76f0c1186..49cc7e56fad098060f882735bde283497dfb6486 100644 (file)
@@ -154,7 +154,8 @@ function tag_print_management_box($tag_object, $return=false) {
 
         // only people with moodle/tag:edit capability may edit the tag description
         if ( has_capability('moodle/tag:edit', $systemcontext) && 
-                (tag_record_tagged_with(array('type'=>'user', 'id'=>$USER->id), $tag_object->name) || is_siteadmin($USER->id)) ) {
+                (tag_record_tagged_with(array('type'=>'user', 'id'=>$USER->id), $tag_object->name) || 
+                 has_capability('moodle/tag:manage', $systemcontext)) ) {
             $links[] = '<a href="'. $CFG->wwwroot .'/tag/edit.php?tag='. rawurlencode($tag_object->name) .'">'. get_string('edittag', 'tag') .'</a>';
         }