You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Depends on how you structure the implementation of your collection. If you had page and per_page attributes on the collection (recommended), then
classFoo::Things < Foo::Collectionattribute:pageattribute:per_pagedefallloadget_things(page: page,per_page: per_page).dataendendFoo.new.things(page: 1,per_page: 3).each{|thing| thing.call}# works
The following works when you consider #all() with arguments
classFoo::Things < Foo::Collectiondefall(page:,per_page:)loadget_things(page: page,per_page: per_page).dataendendFoo.new.things(page: 1,per_page: 3).each{|thing| thing.call}# does not workFoo.new.things.all(page: 1,per_page: 3).each{|thing| thing.call}# works
When loading a collection if you do
the parameters won't get passed through to the
all
call that theload_records
method calls.It works if you call
The text was updated successfully, but these errors were encountered: