Commit d5327021 authored by Dan Poltawski's avatar Dan Poltawski
Browse files

Merge branch 'MDL-53440-master' of git://github.com/cameron1729/moodle

parents c62fa3c0 1b276bfc
......@@ -55,6 +55,9 @@ if ($returnto === 'url' && confirm_sesskey() && $returnurl) {
case 'topcat':
$returnurl = new moodle_url($CFG->wwwroot . '/course/');
break;
case 'pending':
$returnurl = new moodle_url($CFG->wwwroot . '/course/pending.php');
break;
}
}
}
......
......@@ -51,7 +51,7 @@ if (!empty($approve) and confirm_sesskey()) {
$courseid = $course->approve();
if ($courseid !== false) {
redirect($CFG->wwwroot.'/course/edit.php?id=' . $courseid);
redirect(new moodle_url('/course/edit.php', ['id' => $courseid, 'returnto' => 'pending']));
} else {
print_error('courseapprovedfailed');
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment