Skip to content

Commit b4eede9

Browse files
coderimusdimonovp
authored andcommitted
Hotfix: change the way of checking array size and condition check
1 parent 73099fd commit b4eede9

File tree

1 file changed

+2
-2
lines changed
  • app/code/Magento/Backend/Model/Widget/Grid

1 file changed

+2
-2
lines changed

app/code/Magento/Backend/Model/Widget/Grid/Parser.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,8 @@ public function parseExpression($expression)
3030
$expression = trim($expression);
3131
foreach ($this->_operations as $operation) {
3232
$splittedExpr = preg_split('/\\' . $operation . '/', $expression, -1, PREG_SPLIT_DELIM_CAPTURE);
33-
if (!empty($splittedExpr)) {
34-
$count = count($splittedExpr);
33+
$count = count($splittedExpr);
34+
if ($count > 1) {
3535
for ($i = 0; $i < $count; $i++) {
3636
$stack = array_merge($stack, $this->parseExpression($splittedExpr[$i]));
3737
if ($i > 0) {

0 commit comments

Comments
 (0)