diff --git a/src/Search/Response.php b/src/Search/Response.php index 365d27c6..78072012 100644 --- a/src/Search/Response.php +++ b/src/Search/Response.php @@ -19,6 +19,7 @@ use MonsieurBiz\SyliusSearchPlugin\Search\Request\RequestConfiguration; use Pagerfanta\Adapter\AdapterInterface; use Pagerfanta\Pagerfanta; +use Traversable; class Response implements ResponseInterface { @@ -50,12 +51,12 @@ public function __construct( $this->buildFilters(); } - public function getIterator() + public function getIterator(): Traversable { return $this->getPaginator(); } - public function count() + public function count(): int { return $this->getPaginator()->getNbResults(); }