Skip to content

Commit

Permalink
Merge pull request #1656 from ConductionNL/fix/logcontroller
Browse files Browse the repository at this point in the history
Set defaults for limit and start
  • Loading branch information
rjzondervan authored Jul 8, 2024
2 parents ab686c8 + ccff10c commit 4b23a18
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions api/src/Controller/LogController.php
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,9 @@ public function logAction(Request $request): Response
$this->handleFilterArray($key, $value);
}

$limit = 30;
$start = 0;

$completeFilter = $this->cacheService->setPagination($limit, $start, $completeFilter);

$order = isset($completeFilter['_order']) === true ? str_replace(['ASC', 'asc', 'DESC', 'desc'], [1, 1, -1, -1], $completeFilter['_order']) : [];
Expand Down

0 comments on commit 4b23a18

Please sign in to comment.