Skip to content
This repository has been archived by the owner on Mar 3, 2023. It is now read-only.

Commit

Permalink
Add some static type-hints, remove some casts
Browse files Browse the repository at this point in the history
  • Loading branch information
Sam Stenvall committed May 22, 2018
1 parent 3090b81 commit 1ecaeb2
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/Search/Search.php
Original file line number Diff line number Diff line change
Expand Up @@ -198,9 +198,9 @@ public function addAggregations(array $aggregations)
* @param int $page
* @return Search
*/
public function setPage($page)
public function setPage(int $page)
{
$this->page = (int)$page;
$this->page = $page;
return $this;
}

Expand All @@ -217,7 +217,7 @@ public function getFrom()
*
* @return Search
*/
public function setFrom($from)
public function setFrom(int $from)
{
$this->from = $from;

Expand All @@ -238,9 +238,9 @@ public function getSize()
* @param int $size
* @return Search
*/
public function setSize($size)
public function setSize(int $size)
{
$this->size = (int)$size;
$this->size = $size;
return $this;
}

Expand Down

0 comments on commit 1ecaeb2

Please sign in to comment.