Skip to content

Commit

Permalink
why doesn't Kaminari.paginate_array accept options?
Browse files Browse the repository at this point in the history
  • Loading branch information
amatsuda committed Dec 21, 2011
1 parent aa99b78 commit 7f563a4
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions lib/kaminari/models/array_extension.rb
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,11 @@ def offset(num)
end

# Wrap an Array object to make it paginatable
def self.paginate_array(array)
PaginatableArray.new array
# ==== Options
# * <tt>:limit</tt> - limit
# * <tt>:offset</tt> - offset
# * <tt>:total_count</tt> - total_count
def self.paginate_array(array, options = {})
PaginatableArray.new array, options
end
end

0 comments on commit 7f563a4

Please sign in to comment.