MDL-29019 enrol - fix a typo
authorSun Zhigang <sunner@gmail.com>
Sat, 20 Aug 2011 03:24:04 +0000 (11:24 +0800)
committerEloy Lafuente (stronk7) <stronk7@moodle.org>
Tue, 23 Aug 2011 23:30:57 +0000 (01:30 +0200)
enrol/self/lib.php

index 4ca0beb..d86d0cb 100644 (file)
@@ -153,7 +153,7 @@ class enrol_self_plugin extends enrol_plugin {
     public function get_newinstance_link($courseid) {
         $context = get_context_instance(CONTEXT_COURSE, $courseid, MUST_EXIST);
 
-        if (!has_capability('moodle/course:enrolconfig', $context) or !has_capability('enrol/manual:config', $context)) {
+        if (!has_capability('moodle/course:enrolconfig', $context) or !has_capability('enrol/self:config', $context)) {
             return NULL;
         }
         // multiple instances supported - different roles with different password