Skip to content

Commit 9c544b0

Browse files
authored
Add Searchkick::Relation#per as alias for per_page (#1736)
Fixes compatibility with api-pagination which expects `per` to be present.
1 parent f767937 commit 9c544b0

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

lib/searchkick/relation.rb

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -409,6 +409,8 @@ def per_page(value = NO_DEFAULT_VALUE)
409409
end
410410
end
411411

412+
alias_method :per, :per_page
413+
412414
def per_page!(value)
413415
check_loaded
414416
# TODO set limit?

0 commit comments

Comments
 (0)