MDL-83786 navigation: Correct incorrect paren in navfilter
This condition was checking whether navgfilter was true, and the stringfilter was also true. In most cases the condition will have actually worked correctly, albeit by fluke. For users upgrading or otherwise missing the navfilter configuration this condition led to warnings.
This commit is contained in:
@@ -3488,7 +3488,7 @@ EOD;
|
||||
}
|
||||
|
||||
// If filtering of the primary custom menu is enabled, apply only the string filters.
|
||||
if (!empty($CFG->navfilter && !empty($CFG->stringfilters))) {
|
||||
if (!empty($CFG->navfilter) && !empty($CFG->stringfilters)) {
|
||||
// Apply filters that are enabled for Content and Headings.
|
||||
$filtermanager = \filter_manager::instance();
|
||||
$custommenuitems = $filtermanager->filter_string($custommenuitems, \context_system::instance());
|
||||
@@ -3511,7 +3511,7 @@ EOD;
|
||||
}
|
||||
|
||||
// If filtering of the primary custom menu is enabled, apply only the string filters.
|
||||
if (!empty($CFG->navfilter && !empty($CFG->stringfilters))) {
|
||||
if (!empty($CFG->navfilter) && !empty($CFG->stringfilters)) {
|
||||
// Apply filters that are enabled for Content and Headings.
|
||||
$filtermanager = \filter_manager::instance();
|
||||
$custommenuitems = $filtermanager->filter_string($custommenuitems, \context_system::instance());
|
||||
|
||||
Reference in New Issue
Block a user