fixed use of context when formatting instance names
authorPetr Skoda <skodak@moodle.org>
Wed, 11 Aug 2010 17:15:52 +0000 (17:15 +0000)
committerPetr Skoda <skodak@moodle.org>
Wed, 11 Aug 2010 17:15:52 +0000 (17:15 +0000)
lib/enrollib.php

index d46d369..c7738f1 100644 (file)
@@ -709,7 +709,8 @@ abstract class enrol_plugin {
             $enrol = $this->get_name();
             return get_string('pluginname', 'enrol_'.$enrol);
         } else {
-            return format_string($instance->name);
+            $context = get_context_instance(CONTEXT_COURSE, $instance->courseid);
+            return format_string($instance->name, true, array('context'=>$context));
         }
     }