From e0904abe80a0cfb340e6e8b450a4251bdf824af5 Mon Sep 17 00:00:00 2001 From: ADmad Date: Thu, 9 Sep 2021 23:02:14 +0530 Subject: [PATCH] Remove redundant condition. --- src/Datasource/Paginator.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Datasource/Paginator.php b/src/Datasource/Paginator.php index 8c67c985818..3cabf61de9d 100644 --- a/src/Datasource/Paginator.php +++ b/src/Datasource/Paginator.php @@ -669,7 +669,7 @@ protected function _prefix(RepositoryInterface $object, array $order, bool $allo public function checkLimit(array $options): array { $options['limit'] = (int)$options['limit']; - if (empty($options['limit']) || $options['limit'] < 1) { + if ($options['limit'] < 1) { $options['limit'] = 1; } $options['limit'] = max(min($options['limit'], $options['maxLimit']), 1);