Skip to content

Commit

Permalink
EZP-31328: Added support for recursive resolving of query parameters
Browse files Browse the repository at this point in the history
  • Loading branch information
adamwojs authored and bdunogier committed Jan 27, 2020
1 parent a71f5df commit 642b225
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/API/QueryFieldService.php
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,11 @@ public function countContentItems(Content $content, string $fieldDefinitionIdent
private function resolveParameters(array $parameters, array $variables): array
{
foreach ($parameters as $key => $expression) {
$parameters[$key] = $this->resolveExpression($expression, $variables);
if (is_array($expression)) {
$parameters[$key] = $this->resolveParameters($expression, $variables);
} else {
$parameters[$key] = $this->resolveExpression($expression, $variables);
}
}

return $parameters;
Expand Down

0 comments on commit 642b225

Please sign in to comment.