Skip to content
Permalink
Browse files

Simplify whitelist logic.

  • Loading branch information...
markstory committed Jul 16, 2013
1 parent d4db64f commit a8f4ec0450031071159048e78fc8af4ceb3e6758
Showing with 1 addition and 4 deletions.
  1. +1 −4 lib/Cake/Controller/Component/PaginatorComponent.php
@@ -377,11 +377,8 @@ public function validateSort(Model $object, array $options, array $whitelist = a
$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'])) {

0 comments on commit a8f4ec0

Please sign in to comment.
You can’t perform that action at this time.