Skip to content

Commit f0ef0e2

Browse files
committed
♻️ code cleaning
1 parent 7d1d364 commit f0ef0e2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Drivers/Standard/ParamsValidator.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ public function validateScopes(Request $request): void
4747

4848
public function validateFilters(Request $request): void
4949
{
50-
$max_depth = ceil(($this->getArrayDepth($request->all()['filters'])) / 2) - 1;
50+
$max_depth = floor($this->getArrayDepth($request->all()['filters']) / 2);
5151
$config_max_nested_depth = config('orion.search.max_nested_depth', 1);
5252

5353
abort_if($max_depth > $config_max_nested_depth, 422, __('Max nested depth :depth is exceeded', ['depth' => $config_max_nested_depth]));

0 commit comments

Comments
 (0)