mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2025-09-07 20:12:42 +00:00
Check whether the filter key is a valid class name before assuming that value is class settings
This commit is contained in:
parent
1e29070d55
commit
eb14a64d0b
2 changed files with 11 additions and 1 deletions
|
@ -97,7 +97,7 @@ class Dispatcher implements CakeEventListener {
|
|||
|
||||
foreach ($filters as $index => $filter) {
|
||||
$settings = array();
|
||||
if (is_array($filter) && !is_int($index)) {
|
||||
if (is_array($filter) && !is_int($index) && class_exists($index)) {
|
||||
$settings = $filter;
|
||||
$filter = $index;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue