Added the empty condition in the __get_page_sizes method of the Pagination utility.
This commit is contained in:
parent
1a44f08b90
commit
a7a432914d
@ -241,6 +241,8 @@ class Pagination(t.Generic[T]):
|
||||
|
||||
:return: The available page sizes.
|
||||
"""
|
||||
if not self.is_paged:
|
||||
return []
|
||||
return [Link(str(x), self.__uri_size(x),
|
||||
is_current=x == self.__page_size)
|
||||
for x in self.AVAILABLE_PAGE_SIZES]
|
||||
|
Loading…
Reference in New Issue
Block a user