mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2025-01-19 02:56:15 +00:00
Simplify whitelist logic.
This commit is contained in:
parent
d4db64ff26
commit
a8f4ec0450
1 changed files with 1 additions and 4 deletions
|
@ -377,11 +377,8 @@ class PaginatorComponent extends Component {
|
|||
$inWhitelist = in_array($field, $whitelist, true);
|
||||
if (!$inWhitelist) {
|
||||
$options['order'] = null;
|
||||
return $options;
|
||||
}
|
||||
if ($inWhitelist) {
|
||||
return $options;
|
||||
}
|
||||
return $options;
|
||||
}
|
||||
|
||||
if (!empty($options['order']) && is_array($options['order'])) {
|
||||
|
|
Loading…
Add table
Reference in a new issue