mirror of
https://github.com/moodle/moodle.git
synced 2025-08-05 00:46:50 +02:00
MDL-40241 core_completion: Minor fixes to provided patch
Thanks to Aaron Barnes and Jon Sharp for working on this issue.
This commit is contained in:
parent
525d6ce397
commit
95d1a366ea
5 changed files with 51 additions and 59 deletions
|
@ -34,7 +34,7 @@ $cmid = optional_param('id', 0, PARAM_INT);
|
|||
$courseid = optional_param('course', 0, PARAM_INT);
|
||||
$confirm = optional_param('confirm', 0, PARAM_BOOL);
|
||||
|
||||
// Check if we are marking a user complete via the completion report
|
||||
// Check if we are marking a user complete via the completion report.
|
||||
$user = optional_param('user', 0, PARAM_INT);
|
||||
$rolec = optional_param('rolec', 0, PARAM_INT);
|
||||
|
||||
|
@ -56,7 +56,7 @@ if ($courseid) {
|
|||
|
||||
if (!$completion->is_enabled()) {
|
||||
throw new moodle_exception('completionnotenabled', 'completion');
|
||||
} elseif (!$completion->is_tracked_user($trackeduser)) {
|
||||
} else if (!$completion->is_tracked_user($trackeduser)) {
|
||||
throw new moodle_exception('nottracked', 'completion');
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue