mirror of
https://github.com/moodle/moodle.git
synced 2025-04-27 03:14:20 +02:00
MDL-37572 - fix typo in has_any_capability()
This commit is contained in:
parent
8c8d314ffd
commit
ef5a82104c
@ -505,7 +505,7 @@ if (!$courses) {
|
||||
|
||||
// Change visibility.
|
||||
// Users with no capability to view hidden courses, should not be able to lock themselves out.
|
||||
if (has_all_capability(array('moodle/course:visibility', 'moodle/course:viewhiddencourses'), $coursecontext)) {
|
||||
if (has_any_capability(array('moodle/course:visibility', 'moodle/course:viewhiddencourses'), $coursecontext)) {
|
||||
if (!empty($acourse->visible)) {
|
||||
$url = new moodle_url($baseurl, array('hide' => $acourse->id));
|
||||
$icons[] = $OUTPUT->action_icon($url, new pix_icon('t/hide', get_string('hide')));
|
||||
@ -755,4 +755,4 @@ function print_category_edit(html_table $table, $category, $displaylist, $parent
|
||||
print_category_edit($table, $cat, $displaylist, $parentslist, $depth+1, $up, $down);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user