Merge pull request #5104 from ntd/pr3

FIX Do not hang on nested parameters in search context
This commit is contained in:
Damian Mooyman 2016-02-29 10:29:05 +13:00
commit 6c74481462

View File

@ -212,7 +212,10 @@ abstract class ModelAdmin extends LeftAndMain {
$params = $this->getRequest()->requestVar('q');
if(is_array($params)) {
$params = array_map('trim', $params);
$trimRecursive = function($v) use(&$trimRecursive) {
return is_array($v) ? array_map($trimRecursive, $v) : trim($v);
};
$params = $trimRecursive($params);
}
$list = $context->getResults($params);