We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent be957aa commit a099535Copy full SHA for a099535
lib/api-pagination.rb
@@ -25,7 +25,7 @@ def pages_from(collection)
25
pages[:prev] = collection.current_page - 1
26
end
27
28
- unless collection.last_page?
+ unless collection.last_page? || (ApiPagination.config.paginator == :kaminari && collection.out_of_range?)
29
pages[:last] = collection.total_pages
30
pages[:next] = collection.current_page + 1
31
0 commit comments