portfolio/lib MDL-15995 Added a missing global declaration for $CFG that broke cron
authorMartin Dougiamas <martin@moodle.com>
Thu, 17 Dec 2009 03:33:45 +0000 (03:33 +0000)
committerMartin Dougiamas <martin@moodle.com>
Thu, 17 Dec 2009 03:33:45 +0000 (03:33 +0000)
lib/portfoliolib.php

index 849f62c..a38259b 100644 (file)
@@ -918,7 +918,8 @@ function portfolio_handle_event($eventdata) {
 * @todo add hooks in the plugins - either per instance or per plugin
 */
 function portfolio_cron() {
-    global $DB;
+    global $DB, $CFG;
+
     require_once($CFG->libdir . '/portfolio/exporter.php');
     if ($expired = $DB->get_records_select('portfolio_tempdata', 'expirytime < ?', array(time()), '', 'id')) {
         foreach ($expired as $d) {