kaminari
kaminari copied to clipboard
Fix page_entries_info when array is empty
This fixes #1013
Previously, the code was not taking into account that you can call paginate_array
with an empty array, while passing in the total_count
.
This fix checks to see if the records are empty or not. If they are, then the to
variable uses a different calculation.
@amatsuda Hi. Any feedback on this PR?
@monfresh Thank you!
@amatsuda Would you be able to release a new version with my fix please? Thanks!