-
Notifications
You must be signed in to change notification settings - Fork 52
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
current_page
Method Missing After Upgrading meilisearch-rails
#394
Comments
Thank you for your report! I believe I can see why this is happening, I should have been more careful reviewing that PR... Expect a fix in less than an hour. |
This is the relevant code in Kaminari: https://github.com/kaminari/kaminari/blob/f96e022d0d7540c2e6455debb7992a9a6244a9cb/kaminari-core/lib/kaminari/models/array_extension.rb#L21 This was happening due to the limit not being set properly. |
I just gave #395 a try and can confirm that it fixes the issue. |
Fixes regression in meilisearch#376 Fixes meilisearch#394
Description
After upgrading to the latest version (0.41.2) of
meilisearch-rails
, thecurrent_page
method is no longer available on the search result object when using Kaminari pagination. I downgraded to 0.41.1 and it works again. Related #376Expected behavior
Calling
.current_page
on the search results should return the current page number.Current behavior
Calling
.current_page
results in aNoMethodError
:Screenshots or Logs
Environment (please complete the following information):
The text was updated successfully, but these errors were encountered: