Fixed sorting by groups in Flex Users

This commit is contained in:
Matias Griese
2020-11-09 19:47:00 +02:00
parent 3df099a0e3
commit d3f1f833ab
2 changed files with 4 additions and 3 deletions

View File

@@ -20,6 +20,7 @@
* Fixed media crashing on a bad image
* Fixed bug in collections where filter `type: false` did not work
* Fixed `print_r()` in twig
* Fixed sorting by groups in `Flex Users`
# v1.7.0-rc.17
## 10/07/2020
@@ -500,7 +501,6 @@
* Fixed hardcoded system folder in blueprints, config and language streams
* Added `.htaccess` rule to block attempts to use Twig in the request URL
# v1.6.28
## 10/07/2020

View File

@@ -11,6 +11,7 @@ namespace Grav\Framework\Object\Collection;
use Doctrine\Common\Collections\Expr\ClosureExpressionVisitor;
use Doctrine\Common\Collections\Expr\Comparison;
use function is_callable;
class ObjectExpressionVisitor extends ClosureExpressionVisitor
{
@@ -27,7 +28,7 @@ class ObjectExpressionVisitor extends ClosureExpressionVisitor
$pos = strpos($field, '(');
if (false !== $pos) {
list ($op, $field) = explode('(', $field, 2);
[$op, $field] = explode('(', $field, 2);
$field = rtrim($field, ')');
}
@@ -39,7 +40,7 @@ class ObjectExpressionVisitor extends ClosureExpressionVisitor
foreach ($accessors as $accessor) {
$accessor .= $field;
if (!method_exists($object, $accessor)) {
if (!is_callable([$object, $accessor])) {
continue;
}