MDL-33398 Cron: fix wrong variable type in completion criterias
[moodle.git] / lib / completion / completion_criteria_course.php
index 671eeb9..a25dea2 100644 (file)
@@ -194,7 +194,7 @@ class completion_criteria_course extends completion_criteria {
         $rs = $DB->get_recordset_sql($sql);
         foreach ($rs as $record) {
             $completion = new completion_criteria_completion((array) $record, DATA_OBJECT_FETCH_BY_KEY);
-            $completion->mark_complete($record['timecompleted']);
+            $completion->mark_complete($record->timecompleted);
         }
         $rs->close();
     }