src/Hydra/Serializer/PartialCollectionViewNormalizer.php 1 location
|
@@ 56-61 (lines=6) @@
|
53 |
|
|
54 |
|
$currentPage = $lastPage = $itemsPerPage = $pageTotalItems = null; |
55 |
|
if ($paginated = $object instanceof PartialPaginatorInterface) { |
56 |
|
if ($object instanceof PaginatorInterface) { |
57 |
|
$paginated = 1. !== $lastPage = $object->getLastPage(); |
58 |
|
} else { |
59 |
|
$itemsPerPage = $object->getItemsPerPage(); |
60 |
|
$pageTotalItems = (float) count($object); |
61 |
|
} |
62 |
|
|
63 |
|
$currentPage = $object->getCurrentPage(); |
64 |
|
} |
src/Serializer/AbstractCollectionNormalizer.php 1 location
|
@@ 93-98 (lines=6) @@
|
90 |
|
$currentPage = $lastPage = $itemsPerPage = $pageTotalItems = $totalItems = null; |
91 |
|
|
92 |
|
if ($paginated = $paginator = $object instanceof PartialPaginatorInterface) { |
93 |
|
if ($object instanceof PaginatorInterface) { |
94 |
|
$paginated = 1. !== $lastPage = $object->getLastPage(); |
95 |
|
$totalItems = $object->getTotalItems(); |
96 |
|
} else { |
97 |
|
$pageTotalItems = (float) count($object); |
98 |
|
} |
99 |
|
|
100 |
|
$currentPage = $object->getCurrentPage(); |
101 |
|
$itemsPerPage = $object->getItemsPerPage(); |