Add expected type-hint to BoundariesPager::renderFull

- Address https://github.com/friendica/friendica/issues/11630#issuecomment-1162634199
This commit is contained in:
Hypolite Petovan 2022-06-22 07:49:45 -04:00
parent 7295138f8d
commit e9f7bb477d
2 changed files with 3 additions and 3 deletions

View File

@ -130,7 +130,7 @@ class BoundariesPager extends Pager
return Renderer::replaceMacros($tpl, ['pager' => $data]); return Renderer::replaceMacros($tpl, ['pager' => $data]);
} }
public function renderFull(int $itemCount) public function renderFull(int $itemCount): string
{ {
throw new \BadMethodCallException(); throw new \BadMethodCallException();
} }

View File

@ -199,13 +199,13 @@ class Pager
* *
* $html = $pager->renderFull(); * $html = $pager->renderFull();
* *
* @param integer $itemCount The total number of items including those note displayed on the page * @param int $itemCount The total number of items including those note displayed on the page
* @return string HTML string of the pager * @return string HTML string of the pager
* @throws \Friendica\Network\HTTPException\InternalServerErrorException * @throws \Friendica\Network\HTTPException\InternalServerErrorException
*/ */
public function renderFull(int $itemCount): string public function renderFull(int $itemCount): string
{ {
$totalItemCount = max(0, intval($itemCount)); $totalItemCount = max(0, $itemCount);
$data = []; $data = [];